0

I am trying to identify the hardware that my PowerShell based benchmark is running from. I can get the Drive letter easy enough, and with Win32_Volume I can get some useful information like disk format. And with Win32_diskdrive I can get some information about a drive itself. But how do I get from Win32_Volume to Win32_diskdrive? The latter has a DeviceID, but I can't see that ID referenced anywhere in the Win32_Volume data. I have also looked at Win32_PhysicalMedia and I don't see any breadcrumbs to follow there either. So, given PowerShell 2.0 & WMI, how does one get from a drive letter to the physical disk the volume that drive letter represents is housed on?

Gordon
  • 6,257
  • 6
  • 36
  • 89
  • I think Get-Disk is PS 3.0, and I am limited to 2.0 for a number of reasons beyond my control. But I would have thought just with WMI it could be done. – Gordon Sep 16 '16 at 16:12
  • Doh! I had found Get-Disk and knew it didn't work, and didn't follow the link. Sorry! Looks – Gordon Sep 16 '16 at 16:39

0 Answers0