domingo, 30 de octubre de 2016

Lock .vmdk or .vmx



How to know what host is locking the VM?


Sometimes in VMware vSphere after a HA event some vms has an startup failed; occasionally is the vCenter Virtual Machine.  So if you have access to the datastore files you can know how to find that host  has some process that don´t let you start the virtual machine, here the answer:

So, we first to find the datastore, just put this command in your ssh client connected to the esxi host :

1.  With this command you can find and identify the datastore connected to the esxi host.

      df -h 

2.  Use this command for find the host that has locked the virtual machine.

vmfsfilelockinginfo -p /vmfgs/volumes/yourdatastore/yourlostvm/yourlostvm.vmx or yourlostvm.vmdk  -v ipofvcenterserveraddress  -u administrator@vsphere.local

In this image you can see the process.




3.  After that you need to connect to the host en look for the vm process.

     esxcli vm process list

     Take note of the Worl ID number.

4.  In this step you need to user the world id number
     
      esxcli vm process kill -t soft -w yourworlidnumber

      This the KB about the 3 and 4 steps: https://kb.vmware.com/selfservice/microsites/search.do?         language=en_US&cmd=displayKC&externalId=1014165 


Thanks for visiting my Blog!!!

Share and be sociable!!!

No hay comentarios:

Publicar un comentario

Installing Kubernetes on RHEL 9

  Hello Guys, In this post I will show you how to install a Kubernetes cluster on RHEL8. Let's Start: Disablle Swapp: sudo swapoff -a Co...