PowerShell

Last-modified: 2013-04-14 (日) 13:30:29
amazon.gif

Tips

・ハードディスクの残り容量を調べる

PS> Get-WmiObject Win32_LogicalDisk

・画面に表形式に表示する。

PS> Get-WmiObject Win32_LogicalDisk | Format-Table

・GB単位で表示する

PS>get-WmiObject Win32_LogicalDisk | Format-Table DeviceID,@{Label="FreeSpace(GB)"; Expression={"{0,5:f1}" -f ($_.FreeSpace / 1GB)}},Description,DeviceType -Auto
 

システム管理

環境設定

・「スクリプトの実行がシステムで無効になっているため・・・」と表示されたら

PS > Set-ExecutionPolicy RemoteSigned を実行する。

・参考
 http://www.atmarkit.co.jp/fwin2k/operation/psh02/psh02_01.html

 

読み物

参考書籍

 
amazon.gif

サイト内リンク

マクロ

OS系

参考

・WebCast
http://www.microsoft.com/japan/windowsserver2008/r2/webcast/contents/WindowsPowerShell/play.htm