I just inherited a medium-scale Virtual Environment of just over 100 VMs on three different networks. Unfortunatly, my predicessor did not inventory the physcial hard disks utilized in my 19 physical servers, and if possible, I need a way to identify thier serial numbers without bringing the server down.

Is there a console command that can query this information?

I have a mix of Dell and HP servers, if that in any way helps.

  • 5
    Why do you need their serial numbers?
    – Chopper3
    Aug 10 '11 at 15:24
  • 1
    Chopper - I need the SNs because I have to account for every single item I have in my data center, including every HDD. The only way to accuratly do that is by serial number. Aug 10 '11 at 15:54
  • 4
    @DodgerUSMC - that's seriously anal - though I'm assuming that one part of your user name shows why, still, seriously control-freakish :)
    – Chopper3
    Aug 10 '11 at 16:14
  • 1
    @DodgerUSMC: the only place a serial number matters is through the vendor; start there, seriously: why do all this inventory yourself when a Dell service tag can tell you everything you need to know about the system.
    – gravyface
    Aug 10 '11 at 17:07
  • 1
    @Chopper - Oh brother, you aint lyin'. Anal doesn't even begin to describe the level of detail we maintain about our IT ewuipment. Most of these servers house sensitive data, to the point that the loss of one of them would be a big deal. Thus the by-serial-number accountability. Aug 11 '11 at 1:39

I know you can get this with sdparm, but it's doubtful it's installed. Might be in dmesg; the drive model should be in there at least and you'll need to access tech support mode first.

What I would do is just inventory the Dell service tags (and whatever the HP equivalent is; some others can probably assist there) of the servers and use the vendor's lookup tool to see what shipped with the server, what the warranty covers, etc.

Dell tags should be right on the front of the server if rack mounted or top-front if tower.

You should be able to get this from the tech support mode with dmidecode if it's installed with: dmidecode |grep -i "serial number" and that might even work for the HP servers.


Another option (assuming you're using vCenter) would be to install the Dell vCenter plugin; it gives you OpenManage-like functionality (including a complete hardware inventory) for your Dell ESXi hosts. I would imagine that HP has something similar.

Probably the best option for not just disk serial numbers, but for ongoing monitoring/management of the ESXi hosts' hardware.

  • 1
    Thanks for the reply gravyface. I should clarify now that these servers are all more than three years old, and the odds of them having the shipped HDDs still in them are extremely low. I know for a fact that these servers have been in three different continents in the past three years, and in various states of maintenance. Aug 10 '11 at 15:53
  • Why would that be "extremely low"? I have dozens of 3-year old servers out there with the original drives in them or the odd one replaced within warranty; I would say that's pretty typical. Any replacements would likely be with the vendor service history. I'd start there; save yourself some work.
    – gravyface
    Aug 10 '11 at 16:50
  • 1
    After each use, these HDDs are removed from all servers and placed into a shipping container with no note of where they were installed. They are then shipped to another group of admins whos SOP is to throw the drives into the servers upon arrival, re-initialize, and reformat. Its a less-than-idea setup, believe me. Aug 10 '11 at 17:17
  • 1
    the warranty on these servers expired long ago. And yes, I have a full cluster of NetApp filers hosting the VMs. Aug 11 '11 at 1:32
  • 1
    Just read your Edit. I am using vCenter. That actually sounds like a great way to go, and should be easy to pass along to the next guy that gets my job. We are planning to upgrade the servers on all networks in the next 2-3 months to a Dell-only hardware suite, so that fits as well. Thank you for all of your help on this. Aug 11 '11 at 1:36

You can SSH into your ESXi server and use the esxcfg tools to find this information.

# List all Logical Devices known on this system with device information
esxcfg-scsidevs -l

# Filter Logical Devices by display name and vendor
esxcfg-scsidevs -l | egrep -i 'display name|vendor'

# (compact)
# List all Logical Devices each on a single line with limited information
esxcfg-scsidevs -c

Source: https://communities.vmware.com/thread/475325

See Also: Identifying disks when working with VMware ESXi/ESX


In VMWare ESXI the serial number of physical hard disks are at the end of their name. The whole name looks somthing like


and the serial number is the last part of it.


maybe using the vmware api: https://www.vmware.com/support/developer/vc-sdk/visdk400pubs/ReferenceGuide/vim.host.ScsiLun.html (search serialnumber on that site). Untested. You would need the vmware sdk

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.