WilliamLam.com

  • About
    • About
    • Privacy
  • VMware Cloud Foundation
  • VKS
  • Homelab
    • Resources
    • Nested Virtualization
  • VMware Nostalgia
  • Apple
You are here: Home / VSAN / vdq - A useful little VSAN utility

vdq - A useful little VSAN utility

02.14.2014 by William Lam // 9 Comments

While re-building a couple of my Nested ESXi VMs for VSAN using some newer builds, I came across a nifty little VSAN utility called vdq which I assume stands for either VMware Disk Query or VSAN Disk Query. I actually found this utility by accident while poking around in the ESXi Shell as I was looking for a quick way to inspect the disks and I know there are a couple other methods which are officially supported by VMware such as RVC or ESXCLI.

Disclaimer: This is not officially supported by VMware, please use at your own risk. 

vdq provides two useful commands, one that queries the disks on your ESXi host and show whether they are eligible or not for VSAN. The other is the disk mappings once VSAN has been configured and enabled on your ESXi host.

To query the disks on your ESXi host, you can run the following command: vdq -q

You will be presented with a lot of useful information such as the disk device name, VSAN node UUID, the state of the disk (whether or not it can be used by VSAN or if it is already in use), reason which includes more details, whether the disk is an SSD or HDD and also if the device is in a PDL (Permanent Device Loss) state.

You can also specify the -H option which makes the output a bit more readable as the default output is using Python. In this next screenshot, if we enable VSAN through the vSphere Web Client we now see that the VSANUUID property is now populated and the state of the disks have now changed.

The next command that is also handy once VSAN is enabled is to quickly get the VSAN disk group mapping by running the following command: vdq -i

With this command you can quickly find out the SSD that is front-ending the set of HDD for a given disk group. This command came in handy while re-building my ESXi hosts as I wanted to blow away the existing VSAN configuration. To do so, you would need to use ESXCLI and by leveraging vdq, I was able to quickly get the disk mappings and more importantly a command I could easily remember.

In general, I would still recommend using either ESXCLI or RVC which is already pretty simple to use but thought I share this little tip if you ever need to just quickly inspect an ESXi host for VSAN.

More from my site

  • A killer custom Apple Mac Mini setup running VSAN
  • Does VSAN work with Free ESXi?
  • ESXi 5.5 Kickstart script for setting up VSAN
  • Does reinstalling ESXi with an existing VSAN Datastore wipe your data?
  • Quick Tip - Steps to shutdown/startup VSAN Cluster w/vCenter running on VSAN Datastore

Categories // VSAN Tags // ESXi 5.5, vdq, VSAN, vSphere 5.5

Comments

  1. *protectedKaruppaiah Venkateswaran says

    09/14/2015 at 10:43 am

    how to get vdq? if there is any link to download vdq utility?

    Reply
    • William Lam says

      09/14/2015 at 2:33 pm

      The utility is located within the ESXi Shell

      Reply
  2. *protectedIonut-Dan Nica says

    05/21/2021 at 3:04 am

    Hi William, do you know if there are API alternatives to VDQ?

    Thanks,
    Ionut

    Reply
    • William Lam says

      05/21/2021 at 6:03 am

      vSAN API 🙂

      Reply

Trackbacks

  1. Welcome to vSphere-land! » VSAN Links says:
    03/01/2014 at 2:23 am

    […] a VSAN Cluster with PowerCLI (Virtu-Al) vdq – A useful little VSAN utility (Virtually Ghetto) VMware VSAN APIs (Virtually Ghetto) Restoring VSAN VM Storage Policies without […]

    Reply
  2. Consolidated list of all Virtual SAN (VSAN) deep dive resources. | says:
    04/09/2014 at 1:31 am

    […] vdq – A useful little VSAN utility (William Lam) […]

    Reply
  3. How to configure an All-Flash VSAN 6.0 Configuration using Nested ESXi? | Uğur PEK says:
    02/28/2015 at 10:17 pm

    […] 1 – We can easily view the IsCapacityFlash property by using our handy vdq VSAN utility which has now been enhanced to include a few more properties. Run the following command to view […]

    Reply
  4. Creating A VMFS Datastore On A USB Drive – VMscrub says:
    05/19/2017 at 11:44 pm

    […] vdq command became available in ESXi version 6. According to Will's blog, vdq stands for VMware Disk Query or VSAN Disk Query. When used with the -q option it will display […]

    Reply
  5. Shell Commands in vSphere ESXi – Part 2 – Blog about the Infrastructure says:
    07/26/2018 at 9:17 am

    […] vdq(VSAN Disk Query) Helps to information of the vSAN disk Reference: https://www.williamlam.com/2014/02/vdq-useful-little-vsan-utility.html […]

    Reply

Thanks for the comment!Cancel reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Search

Thank Author

Author

William is Distinguished Platform Engineering Architect in the VMware Cloud Foundation (VCF) Division at Broadcom. His primary focus is helping customers and partners build, run and operate a modern Private Cloud using the VMware Cloud Foundation (VCF) platform.

Connect

  • Bluesky
  • Email
  • GitHub
  • LinkedIn
  • Mastodon
  • Reddit
  • RSS
  • Twitter
  • Vimeo

Recent

  • Programmatically accessing the Broadcom Compatibility Guide (BCG) 05/06/2025
  • Quick Tip - Validating Broadcom Download Token  05/01/2025
  • Supported chipsets for the USB Network Native Driver for ESXi Fling 04/23/2025
  • vCenter Identity Federation with Authelia 04/16/2025
  • vCenter Server Identity Federation with Kanidm 04/10/2025

Advertisment

Privacy & Cookies: This site uses cookies. By continuing to use this website, you agree to their use.
To find out more, including how to control cookies, see here: Cookie Policy

Copyright WilliamLam.com © 2025