2014. 9. 26. 10:50
- 컬 컴퓨터 및 원격 컴퓨터의 디스크와 관련된 정보를 확인하기 위해서는 Get-WmiObject를 이용하면 된다.
- 먼저 disk와 관련된 Get-WmiObject를 확인하기 위해서 다음과 같이 하면 사용 가능한 목록을 확인할 수 있다.
Get-WmiObject -Class Win32_*Disk* -List - 이제 각각의 정보를 한 번 살펴보자.
Get-WmiObject -Class Win32_LogicalDisk
Get-WmiObject -Class Win32_LogicalDisk -ComputerName Server1
(원격지에 위치한 컴퓨터의 디스크 정보도 알 수 있다.)
Get-WmiObject -Class Win32_MappedLogicalDisk
Get-WmiObject -Class Win32_MappedLogicalDisk -ComputerName Server1
(원격 컴퓨터가 어느 fileserver에 연결되어 있는지 알 수 있다.)
Get-WmiObject -Class Win32_MappedLogicalDisk -ComputerName Server1 | ft name, providername, freespace -autosize
(이렇게 하면 원격 컴퓨터 Server1이 어느 File server에 어떤 드라이브로 연결되어 있는지 간략하게 알 수 있다.)Get-WmiObject -Class Win32_DiskPartition
Get-WmiObject -Class Win32_DiskPartition -ComputerName Server1Get-WmiObject -Class Win32_DiskDrive
Get-WmiObject -Class Win32_DiskPartition -ComputerName Server1Get-WmiObject -Class Win32_DiskQuota
Get-WmiObject -Class Win32_DiskQuota -ComputerName Server1
(각 사용자 단위로 디스크 할당량 정도를 확인할 수 있다. 원격 컴퓨터도 마찬가지.)출처 : http://cloudsns.wordpress.com/category/microsoft/powershell/page/8/
'powershell' 카테고리의 다른 글
특정한 시간 이후에 발생한 이벤트만 확인하기 (0) | 2014.09.26 |
---|---|
네트워크 어댑터(NIC)에 대한 정보 확인하기(Get-WmiObject 이용) (0) | 2014.09.26 |
Disk Controller에 오류가 있는지 확인하기 (0) | 2014.09.26 |
내 시스템에서 사용한 USB Storage 종류 알아보기 (0) | 2014.09.24 |
script에서 Param 사용하여 컴퓨터 정보 확인하기 (0) | 2014.09.24 |