Generating and collecting additional performance statistics for VMware Support
search cancel

Generating and collecting additional performance statistics for VMware Support

book

Article ID: 326274

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

For some performance Service Requests, VMware Support might want you to collect additional virtual machine statistics. This article provides information on how to configure a virtual machine to run with a stats build VMX/virtual machine monitor (VMM), which generates the necessary data.
 

Note: The triple-vmx feature is available only in ESXi 5.0 and later versions.


Environment

VMware vSphere ESXi 6.0
VMware vSphere ESXi 5.5
VMware vSphere ESXi 5.1
VMware vSphere ESXi 5.0

Resolution

To generate additional virtual machine statistics:
  1. Shut down the virtual machine.
  2. Select the virtual machine in the Inventory.
  3. In the Summary tab for that virtual machine, click Edit Settings.
  4. In the Virtual Machine Properties dialog box, click the Options tab.
  5. Under Advanced, click General.
  6. Select the Record Statistics option.
  7. Click OK to save the change.
  8. Power on the virtual machine.

    Note: The statistics are logged over the runtime of the virtual machine and the end result is a summary of all values from boot to shutdown. Use this method only if your workload is consistent and can run long enough to average out the boot time. For example, the statistics collected with a one minute boot time and a 30 second test run may not provide a good representation of the actual workload.
Alternatively, you can use the CLI tool /bin/vmx-buildtype to collect the virtual machine statistics. This tool enables you to change the build type while the virtual machine is running. Note that the recommended method for ESXi 5.1 and later is to use Fast Suspend Resume (FSR). This FSR is usually executed immediately and does not cause any noticeable downtime. Some very large and active workloads might notice a small performance impact similar to a vMotion. You can use the tool from the ESXi Shell directly on the host where the virtual machine is running. For more information on enabling shell access, see Using ESXi Shell in ESXi 5.0 and 5.1 (2004746).
You can also use vmx-buildtype from another system to connect to vCenter Server and any ESXi 5.0 (or later) host. For more information, run this help command:

/bin/vmx-buildtype –help
To generate additional virtual machine statistics using the vmx-buildtype tool:
  1. Run this command and verify that the virtual machine is running on the host:

    vim-cmd vmsvc/getallvms

  2. Start the workload on the virtual machine from which the statistics must be gathered.
  3. Run this command:

    /bin/vmx-buildtype --vmname=<vm-displayname> --server localhost --buildType stats --fsr

  4. Run this command and verify that the virtual machine is now running with the stats VMX/VMM:

    head –n1 /vmfs/volumes/<pathtovm>/vmware.log

    The option should be STATS.

  5. After the test completes, run this command to stop the log collection:

    /bin/vmx-buildtype --vmname=<vm-displayname> --server localhost --buildType release --fsr

  6. Run this command and verify that the virtual machine is now running with the release VMX/VMM:

    head –n1 /vmfs/volumes/<pathtovm>/vmware.log

    The option should now be set to Release.

    Note: ESXi 5.0 only supports the --ssr switch causing a Slow Suspend Resume which will stun the virtual machine while the virtual machine memory is written to disk. This may result in substantial downtime. The stun time in this case is dependent on the memory size of the virtual machine and the storage performance. ESXi 5.1 and later also support the --ssr switch should a FSR not be possible.
For information on collecting the generated logs, see Collecting diagnostic information for VMware ESX/ESXi using the vSphere Client (653).

Additional Information


Using ESXi Shell in ESXi 5.x and 6.x
Collecting diagnostic information for VMware ESX/ESXi