VMWare : ESXi – Powering on a virtual machine from the command line

1. Enable SSH on the ESXi host ( from vSphere client or directly from the console ).

2. Connect to the host using an SSH client ( e.g. PuTTY ) and login using the root account

3. List the inventory ID of the virtual machine with the command:

 vim-cmd vmsvc/getallvms |grep <vm name> 

         **Note: The first column of the output shows the vmid.

4. Check the power state of the virtual machine with the command

vim-cmd vmsvc/power.getstate <vmid>

5. Power-on the virtual machine with the command:

vim-cmd vmsvc/power.on <vmid>
Advertisements

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s