Virtual machines fail to start with the error: Insufficient resources
search cancel

Virtual machines fail to start with the error: Insufficient resources

book

Article ID: 304415

calendar_today

Updated On:

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:
  • Virtual machines fail to start
  • You see the error:

    insufficient resources
  • Virtual machines cannot be started from vSphere Client connected to vCenter Server or directly connected to the ESX host
  • You cannot start virtual machines from the ESX host service console using the command: vmware-cmd /path/to/vmx start
  • The ESX host's/var/log/vmware/hostd.log file contains an entry similar to:

    [...] Insufficient COS swap to power on: need 20 MB, have 6 MB.

    Note: The values in the log entry may vary.

  • This issue occurs even though the service console command free -m shows sufficient free space:

    total used free shared buffers cached
    Mem: 783 702 80 0 225 272
    -/+ buffers/cache: 205 577
    Swap: 596 0 596


    Note: In this example, the free memory in all three columns is higher than that shown in the hostd error message.


Environment

VMware ESX 4.0.x

Resolution

The following workaround prevents the ESX from checking for insufficient COS memory. If possible, set COS memory to 800 MB and ensure that swap is enabled. For more information, see Increasing the amount of RAM assigned to the ESX Server service console (1003501).
  1. Backup the /etc/vmware/hostd/config.xml file with the command:

    cp /etc/vmware/hostd/config.xml /var/tmp/


  2. Edit the /etc/vmware/hostd/config.xml file so that it looks like the following:

    <vmsvc>
    <powerOnCosMinSwapMB> 0 </powerOnCosMinSwapMB> (This line allows the virtual machine to power on)
    <enabled>true</enabled>
    </vmsvc>


  3. Restart the Management agents. For more information, see Restarting the Management agents on an ESX or ESXi Server (1003490).
  4. Start the virtual machines.


Additional Information

仮想マシンが次のエラーで起動に失敗する:リソース不足です
虚拟机无法启动并显示以下错误:资源不足