NetworkSydney

Tag: cluster disks

Powershell - List Disks with Location, Size and Device ID

by Harry on Apr.08, 2010, under Microsoft

Here is a quick one line powershell command to spit out the Location (port, bus, scsi target id, lun id), size (in GB) and Device ID (also known as disk number in the windows gui) into a file.

Get-WmiObject Win32_DiskDrive | select-object DeviceID,{$_.size/1024/1024/1024},scsiport,scsibus,scsitargetid,scsilogicalunit | out-file -FilePath c:\output.txt

Note: This command is one line, watchout for wordwrap!

Leave a Comment :, , , , , , , more...

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

A few highly recommended friends...