Virtual Machine inaccessible(Unknown)

Posted: February 8, 2016 in Uncategorized

If virtual machine is disconnected from ESXI due to vmx file lock, follow the below steps to fix the issue.


Note down the ESXI IP, VM hostname, Ip address & .vmx & .vmdk file path before starting the activity.


Remove the VM from the inventory. Select VM ==> Right click and remove VM from inventory.



Browse the datastore where the .vmx file is located. Right click .vmx file and try adding to the inventory.

If still issue is not resolved. Need to find the lock and it needs to be removed.


Login to ESXI and locate the process ID using below command.

1) esxcli vm process list

Output will be as below.

EG (Output:
World ID: 3338106
Process ID: 0
VMX Cartel ID: 3338103
UUID: 42 00 2c c6 2b d6 17 af-15 58 75 b6 2c 26 f6 10
Display Name: VM
Config File: /vmfs/volumes/531edada-36119f2e-0012-14feb5caca3b/VM/VM.vmx)

Command to kill the process

2) esxcli vm process kill -t (type) -w (world id)

type – soft


Login to esxi and enter the datasore path as below.

(EG) /vmfs/volumes/531edada-36119f2e-0012-14feb5caca3b/virtual machine #

and run the below command to find the NIC which holds the lock.

#vmkfstools -D  VMname.vmx


From above screenshot we can find the lock owner. Here NIC 549f351f04c6 holds the lock.


Run the below command to to check the stale process which holds the lock

#lsof | grep VMname

pK - Copy


Run the command ” kill -9 process Id ” to kill the process.

(EG) kill -9 20425216


Browse the datastore where the .vmx file is located. Now right click .vmx file and add VM to the inventory.

VM’s can also be registered using below command

vim-cmd solo/registervm (datastore path)                 click             click

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s