Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am using a standalone ESX4i server and I have the VMware CLI tools installed.

I have copied a base build VMDK file which has the OS installed and configured and I need to rename the vmdk file to reflect the server name. I am trying to use the CLI tools and am using esxcli.exe.

I am specifed the IP address of the ESX4i host to connect to, but it is failing. How can I rename the vmdk file by using the esxcli.exe tools. I need to use the vmfkstools.pl but it wont connect to the ESX4i host.

I am using something along the lines of

C:\program files\vmware\vmware vshpere clie\bin\esxcli.exe --server=10.2.2.2 vmfkstools.pl

TIA Oli

share|improve this question

1 Answer 1

up vote 1 down vote accepted

The vmkfstools -E parameter allows you to rename VMDKs. It actually looks at the components starting with the base VMDK descriptor (which is a small file with the disk config data) and renames the VMdkname-Flat.vmdk as well.

....\vmkfstools.pl <connection_params> -E /vmfs/volumes/myvmfs/myvmname/vmname.vmdk /vmfs/myvmfs/myvmname/newvmname.vmdk

You can use -E or -renamevirtualdisk they are aliases for the same function.

It is also perfectly safe to use the VI Client's Datastore Browser to do the rename - it hides the fact that the VMDK is comprised of two separate files at the VMFS filesystem level but it still makes sure that any references within the vmdk structure and links to the VMDK get updated properly.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.