Looking for a PowerShell command or WMIC query that will pull the actual NVMe hard drive serial number on a workstation (local and remote). The few that I've ran are displaying the hard drive S/N incorrectly. The commands are showing either the EUI64 number or Part number instead of the actual hard drive S/N which is what I need for a full inventory.
The command I've tried in Powershell is:
Get-PhysicalDisk | select-object friendlyname,serialnumber
Get-WMIObject win32_physicalmedia | format-List tag,serialnumber
Using the command prompt I've tried:
wmic diskdrive get model, name, serialnumber, manufacturer, caption, description
Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.
”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.