Configuring a diagnostic coredump partition on an ESXi host
search cancel

Configuring a diagnostic coredump partition on an ESXi host

book

Article ID: 319492

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

This article provides steps to add a VMKcore diagnostic partition on a local or shared disk post-installation using the esxcli command line utility. A diagnostic partition can also be created using the vSphere Client. For more information, see:

The diagnostic coredump partition is used to capture the output of a purple diagnostic screen in the event of an ESXi host failure. For more information, see Configuring an ESX/ESXi host to capture a VMkernel coredump from a purple diagnostic screen (319635).From vSphere 7.0, coredumps are configured to go to a file in the VMFS-L based ESX-OSData system volume at install and upgrade time. However, if desired, a coredump partition can to be configured as described in this article.

Environment

VMware vSphere ESXi 6.x

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

Resolution

Listing currently configured diagnostic coredump partition on disk

To display the currently configured diagnostic coredump partition:
 

  1. Open a console session to the ESXi host, or the location where vSphere Command-Line Interface (vCLI) is installed.
  2. Retrieve the currently active diagnostic partition by running esxcli command line utility:

    esxcli system coredump partition get

    You see output similar to:

    Active: mpx.vmhba2:C0:T0:L0:7
    Configured: mpx.vmhba2:C0:T0:L0:7

Creating and activating a diagnostic coredump partition on disk

 
Note: Configuring a remote device using the ESXi host software iSCSI adapter, software FCoE adapter or to an NFS mount is not supported.
 

To create a new diagnostic coredump partition on disk:

  1. Open a console session to the ESXi host.

    Note: Diagnostic partitions cannot be created using the vCLI, but existing diagnostic partitions can be activated.
     
  2. Select a storage device with at least 100 MB of free space that is accessible by the ESXi host. For more information, see Identifying disks when working with VMware ESX/ESXi (316540).

    Note:
  3. Run the partedUtil command line utility to create a new partition, 100 MB in size, with type 0xFC = 252. Ensure that other existing partitions on the same disk are not affected. For more information, see Using the partedUtil command line utility on ESXi and ESX (323144).

    Note: Some environments may require a larger size. If needed you will be prompted with the recommended size.
     
  4. Run the esxcli command line utility to list all accessible diagnostic partitions. Validate that the list of partitions includes the one created in step 3.

    esxcli system coredump partition list

    You see output similar to:

    Name Path Active Configured
    --------------------- ------------------ ------ ----------
    mpx.vmhba2:C0:T0:L0:7 /vmfs/devices/.... false false

     
  5. Set and activate one of the accessible diagnostic partitions using the esxcli command line utility. Either specify a device explicitly, or use the Smart Activate feature to automatically select one of the accessible diagnostic partitions:
     
    • To configure and activate a specific device partition by its VMkernel device path, run these commands:

      esxcli system coredump partition set --partition="Partition_Name"
      esxcli system coredump partition set --enable true


      For example:

      esxcli system coredump partition set --partition="mpx.vmhba2:C0:T0:L0:7"
      esxcli system coredump partition set --enable true

       
    • To automatically select and activate an accessible diagnostic partition, run this command:

      esxcli system coredump partition set --enable true --smart
       
  6. Validate that the diagnostic partition is now active by running this command:

    esxcli system coredump partition list

    You see output similar to:

    Name Path Active Configured
    --------------------- ------------------ ------ ----------
    mpx.vmhba2:C0:T0:L0:7 /vmfs/devices/.... true true

Activating or deactivating an existing diagnostic coredump partition on disk using Host Profiles

If a diagnostic partition is available on shared or local disks, it can be activated or deactivated across a group of ESXi 5.x/6.x hosts using Host Profiles.

To configure use of diagnostic coredump partitions using Host Profiles:

  1. Connect to vCenter Server using the vSphere Client.
  2. Click Home and select Host Profiles.
  3. Create or edit a host profile.
  4. Select Coredump Partition Settings > Fixed Coredump Partition Policy.
  5. The configuration option Enable or disable coredump partition is available. Specify the preferred option:
     
    • When deselected, the ESXi host deactivates any previously active diagnostic partition.
    • When selected, the ESXi host automatically selects and activates an accessible diagnostic partition. If a diagnostic partition is already configured, it is activated.
       
  6. Save and apply the host profile.

Additional Information

The environment that does not have Core Dump Configured will receive an Alarm as "Configuration Issues:  No Coredump Target has been Configured Host Core Dumps Cannot be Saved Error".

In the scenarios where the Core Dump partition is not configured and is not needed in the specific environment, you can suppress the Informational Alarm message, following the below steps,

  1. Select the ESXi Host 
  2. Click Configuration > Advanced Settings
  3. Search for UserVars.SuppressCoredumpWarning
  4. Then locate the string and and enter 1 as the value 

The changes takes effect immediately and will suppress the alarm message.

To extract contents from the VMKcore diagnostic partition after a purple screen error.

To identify disks that can be used, see Identifying disks when working with VMware ESXi/ESX