Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

How can I read the paramater called displayName in the .vmx file or "Virtual Machine Name" in vSphere Client from within the VM. If this is possible with vmtoolsd I haven't found it yet.


I have CentOS6 virtual machine templates running under VMware ESXi 5.1. They will get an IP from DHCP when they first come up by randomly generating the last half of the MAC address. However they always have the hostname set as it was when the template was created.


Synchronize virtual machine's hostname (and thus the name it registers in DHCP/DNS) with the name displayed in the vSphere Console.

(If there is a different or better way to get to this goal, that's just as good)

share|improve this question

When you clone the VM from a template, one of the options in the Wizard is to rename the clone. One of the options is to name the host the same as the name in the vSphere inventory.

share|improve this answer

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.