12. Windows Server 2012 R2 の PowerShell
• PowerShell 4.0
• w/ Windows Management Framework 4.0
• モジュール及びコマンドの追加
• PowerShell 4.0 としての追加
• Windows Server 2012 R2 としての追加
※PS 4.0 (WMF 4.0) は Windows Server 2012 R2 以外でも利用可能
– Windows 7 SP1, Windows Server 2008 R2 SP1, Windows Server 2012
– .NET Framework 4.5 が必要
– http://www.microsoft.com/ja-jp/download/details.aspx?id=40855
12
21. DSC リソース
Built-In Resources
Custom Resources
Archive
Environment
File
Resources A
Group
Log
Package
Resources B
Process
Registry
Role
Resources C
Script
Service
User
Resources D
Windows PowerShell Desired State Configuration
21
22. DSC ビルトイン リソース
• Role
• Windows の役割や機能を構成
• User / Group
• ローカルユーザーやグループを構成
• Service
• Windows サービスの状態を構成
• Package
• Windows インストーラーや setup.exe などのパッケージを構成
• File
• ファイルやフォルダーを構成
• etc...
22
42. Hyper-V を管理する際の注意点
• WMI の名前空間
• root¥virtualization 名前空間が Windows Server 2012 R2 で廃止に
– Windows Server 2012 時点で非推奨となっていた
• root¥virtualization¥v2 を使用する
• Windows Server 2008 R2 などからスクリプトを移植する際は注意
42
57. 参考資料
• Windows Server 2012 勉強会キット
• Windows PowerShell 4.0 による Windows Server 2012 R2 の管理 ~
Hyper-V 編
• http://technet.microsoft.com/ja-jp/windowsserver/jj649374.aspx
• Microsoft Virtual Academy
• http://www.microsoftvirtualacademy.com
– Windows Server 2012 管理のための Windows PowerShell 3.0 新機能解説
– Getting Started with PowerShell 3.0 Jump Start
– Windows Server 2012 R2: Server Management and Automation
• PowerShell Advent Calendar 2013
• http://atnd.org/events/45107
57