第一步:
select * from Win32_DiskDrive
第二步:
Associators of {Win32_DiskDrive.DeviceID='\.PHYSICALDRIVE0'} where AssocClass=Win32_DiskDriveToDiskPartition
第三步:
Associators of {Win32_DiskPartition.DeviceID='Disk #0, Partition #1'} where AssocClass=Win32_LogicalDiskToPartition
总结自MSDN: https://docs.microsoft.com/zh-cn/windows/win32/cimwin32prov/win32-logicaldisktopartition?redirectedfrom=MSDN