| Subcribe via RSS

How to kill a VM (VMware ESX 4.0)

July 6th, 2010 Posted in vmware

Alright, it happens from time to time. Virtual Machines get stuck.
Sometimes during boot, sometimes during shutdown and sometimes during a restore operation.

So how do I kill a Virtual Machine?

I wrote this post, back in 2009, for ESX 3.5:
http://technoblog.org/2009/01/how-to-kill-a-stuck-or-hung-vm-vmware-esx-35/

Both the “vmware-cmd /.vmx stop hard” method, and the following methods work, sometimes.. :

1. sudo vm-support -x
2. sudo less -S /proc/vmware/vm//cpu/status
3. sudo /usr/lib/vmware/bin/vmkload_app -k 9

But, when both of those fail? Then what?
How to kill a stuck VM when everything else fails?

It’s a bit brutal, but it works, but be warned, you might corrupt your VM.

1. sudo bash (for simplicity)
2. ps -ax | grep 3. Find the first number to the left, in the string with the right VM. This is the PID.
4. kill -9

Brutal? Yes. Efficient? Yes.

Leave a Reply

technoblog@trap.threatobs.com