Wednesday, September 17, 2008

ESXi Register a Host using the CLI

So you copied a VM's directory and want to move it over to another host, but how do you make it show up in the console so that you can start it.  First you need to go download the VMware Infrastructure Remote CLI tools and install it.  If you are on a windows machine you punch in the following command:

C:\Program Files\VMware\VMware VI Remote CLI\bin>vmware-cmd.pl -H 10.0.200.70 -U root -P myPassword -s register [datastore1]RHEL4/RHEL4.vmx localhost.localdomain default_resource_pool

You will have to create a resource pool and put it in there.  To create one just right click on your datacenter icon in the console and click on New Resource Pool

1 comments:

Kevin said...

I found a much easier way to register a VM with ESXi. Using the datastore browser, browse to your vmx file, right click on it and there is an option to register it.

The datastore browser can be launched from the VI Client under Configuration - storage. Right click on your datastore and choose Browse Datastore.

Kevin