Running the cim-diagnostic.sh or swfw.sh command fails with the error: enumInstances Failed initialization
search cancel

Running the cim-diagnostic.sh or swfw.sh command fails with the error: enumInstances Failed initialization

book

Article ID: 339957

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:
  • CIM subsystem does not work reliably.
  • Running the cim-diagnostic.sh command fails.
  • Running the swfw.sh command fails.
  • When querying the hardware status manually using the cim-diagnostic.sh command or creating a support bundle with the vm-support command, you see messages similar to:

    CIM Diagnostic dump for root/interop
    Dumping instances of CIM_Namespace
    error: enumInstances Failed initialization
    Dumping instances of CIM_RegisteredProfile
    error: enumInstances Failed initialization
    CIM Diagnostic dump for root/cimv2
    Dumping instances of CIM_Sensor


Environment

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

Cause

This issue occurs when IPv6 is disabled on the host, but there is an IPv6 localhost entry in the /etc/hosts file. The cim-diagnostic.sh and swfw.sh scripts invoke the enum_instances command which by default tries to connect to the localhost over IPv6 when the hosts file contains an IPv6 localhost address. Because IPv6 is disabled, the connection and the calling script fails.

Resolution

This is a known issue in VMware ESXi.
To work around this issue, either re-enable IPv6 (requires reboot) or comment out the IPv6 localhost entry in the /etc/hosts file (no reboot required).

To comment the IPv6 localhost entry:

  1. Log in to the host using SSH. For more information, see Using ESXi Shell in ESXi 5.x (2004746).
  2. Edit the hosts file located at /etc/ using a text editor. For more information, see Editing configuration files in VMware ESXi and ESX (1017022).

    Example output:

    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1 localhost.localdomain localhost
    ::1 localhost.localdomain localhost


  3. Comment out IPv6 line that begins with ::1:

    # Do not remove the following line, or various programs
    # that require network functionality will fail.
    127.0.0.1 localhost.localdomain localhost
    #::1 localhost.localdomain localhost

    Note: If the ESXi host is rebooted this workaround will need to be reapplied


Additional Information

For more information, see the Setting Up vSphere Networking with vSphere Standard Switches (especially, To add and configure a VMkernel Network Interface for IPv6) section in the vSphere 5 Command Line Documentation guide.

To be alerted when this document is updated, click the Subscribe to Article link in the Actions box
cim-diagnostic.sh または swfw.sh コマンドを実行すると次のエラーで失敗する:enumInstances が初期化に失敗しました