Discover VM instances on VMware

This document describes the steps to run an inventory discovery on yourVMware environment using the Migration Center discovery client CLI.

Before you begin

  1. Review therequirements for downloading and running themcdc CLI.
  2. Complete the steps todownloadmcdc CLI.

Run an inventory discovery on VMware using vSphere API

Use the vSphere API to collect data about all VMs in a vCenter visible tothe user running themcdc CLI. You can also scope adiscovery to a specific folder, cluster, or data center.

Configure vCenter

If you plan to export the collected data to Migration Center,before you run an inventory discovery, you need to configure your vCenterenvironment.The data you collect withmcdc CLI, in fact, depend onthe settings for statistics in vCenter.

vCenter supports four levels of statistics:

  • Level 1 exposes only CPU and memory performance.
  • Level 2 exposes the network performance.
  • Level 3 exposes input/output operations per second (IOPS).
  • Level 4 exposes all the available metrics.

For a detailed list of the available metrics for all statistics levels, seeData collection levels.

By default, the statistics level is set to level 1. Levels 1 and 2 let youcollect partial data about your infrastructure, while level 3 lets youcollect everything you need to generate a complete total cost of ownership (TCO)report.After the statistics level is changed in vCenter, it might take severalhours for performance data to become available.

For more information on how to change statistics levels in vCenter, seeConfigure statistics collection intervals in the vSphere client.

Run the discovery

  1. In the command line terminal, change to the directory where you downloadedthemcdc CLI.
  2. Run the discovery:

    Linux

    ./mcdc discover vsphere -uUSERNAME --url https://VSPHERE_URL

    Windows

    mcdc.exe discover vsphere -uUSERNAME --url https://VSPHERE_URL

    Replace the following:

    • USERNAME: your vCenter username
    • VSPHERE_URL: the URL for your vCenter Server instance or thevSphere Client

    To avoid a certificate check for connecting to the vCenter,include the-i (insecure) flag in the command.

  3. When prompted, enter the vCenter password.

After the inventory discovery is complete, the collected data is stored in thelocal database.

Scope a discovery

  • Run the discovery at the root:

    Linux

    ./mcdc discover vsphere --url https://VSPHERE_URL -uUSERNAME --path /

    Windows

    mcdc.exe discover vsphere --url https://VSPHERE_URL -uUSERNAME --path /

  • Run the discovery at a specific folder:

    Linux

    ./mcdc discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER/vm/FOLDER

    Windows

    mcdc.exe discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER/vm/FOLDER

    Replace the following:

    • DATACENTER: the name of the data center
    • FOLDER: the path to the folder
  • Run the discovery at a specific cluster:

    Linux

    ./mcdc discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER/host/CLUSTER

    Windows

    mcdc.exe discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER/host/CLUSTER

    Replace the following:

    • CLUSTER: the name of the cluster
  • Run the discovery at a specific data center:

    Linux

    ./mcdc discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER

    Windows

    mcdc.exe discover vsphere --url https://VSPHERE_URL -uUSERNAME --pathDATACENTER

To avoid a certificate check for connecting to the vCenter, include the-i (insecure) flag in the command.

Run an inventory discovery on VMware using RVTools

For VMs running on VMware, themcdc CLI lets you analyzethe XLSX report files generated withRVTools.

  • Collect data based on your existing RVTools export:

    Linux

    ./mcdc discover rvtoolsREPORT_NAME.xlsx

    Windows

    mcdc.exe discover rvtoolsREPORT_NAME.xlsx

    ReplaceREPORT_NAME with the path to the XLSX generatedwith RVTools.

However, this method has following limitations:

  • Themcdc CLI doesn't support tables generatedwith the--DBColumnNames flag in RVTools.
  • Themcdc CLI doesn't support exporting the datacollected using this method to Migration Center. However, you canuse it torun an offline assessment.

What's next

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2026-02-19 UTC.