How to send NMI to Guest OS on ESXi 6.x or Later
search cancel

How to send NMI to Guest OS on ESXi 6.x or Later

book

Article ID: 301246

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

This article provides steps to send a Non-Maskable Interrupt (NMI) to an unresponsive Virtual Machine Guest Operating System on VMware vSphere ESXi 6.x or later to trigger a kernel crash dump.
 
Note: Host client does not include the HungVM - Send_NMI_To_Guest option; therefore, an NMI cannot be sent via the standalone Host Client.



Environment

VMware vSphere ESXi 6.x
VMware vSphere ESXi 7.x
VMware vSphere ESXi 8.x

Cause

An NMI is manually triggered by an administrator when a Guest OS becomes completely unresponsive or hangs, allowing the operating system kernel to generate a crash dump (e.g., Windows Memory Dump or Linux Core Dump) for root cause analysis.

Resolution

To send NMI to Guest OS on ESXi 6.x or Later, use one of these options:
 
  • Using vSphere Client:
     
    1. Log in to the vSphere Web Client/vSphere Client.
    2. Select vCenter from left panel.
    3. Select VMs and Templates.
    4. Right-click Virtual machine > All vCenter Actions > Export Diagnostic Data.
    5. Select HungVM > Send_NMI_To_Guest.
    6. Click Generate Log Bundle.
       
  • Using vm-support command-line:
 
    1. Log in to ESXi host through SSH or console as root.

      Note: The virtual machine must be registered in the inventory.
       
    2. Run this command to list all registered and running virtual machines:

      vm-support --listvms
      vmdumper -l

       
    3. Run this command to Send NMI:

      vm-support -a HungVM:Send_NMI_To_Guest --vm=/vmfs/volumes/Path/of/VMname.vmx

      Note: If the vm is encrypted or Virtualization Based Security (VBS) is enabled then it is necessary to generate a crypto-util key by running the command "crypto-util keys vm-support --password prolog" before running vm-support.  After running the vm-support command clean up the keys by running crypto-util keys vm-support epilog.
  • Using vmdumper command-line:
     
    1. Log in to ESX/ESXi host through SSH or console as root.
    2. Run this command to get a list of all running virtual machines, identified by their World ID, path to the .vmx configuration file:

      ESXi: /sbin/vmdumper -l
      ESX : /usr/lib/vmware/bin/vmdumper -l


      Example output:

      wid=WorldID pid=-1 cfgFile="/vmfs/volumes/path/to/filename.vmx" uuid="ab cd ef ..." displayName="Virtual Machine Name"
       
    3. Run this command to Send NMI:

      vmdumper WorldID nmi



Additional Information

ESXi 6.x 以降でゲスト OS に対して NMI を送信する方法

Using hardware NMI facilities to troubleshoot unresponsive hosts