ESXi: To DHCP or not to DHCP, that is the question

This one has been knocking about in my head for sometime. One of the main manual configurations I have to do with ESXi, is set a number of IP related parameters:

  • Hostname
  • IP
  • Subnet Mask
  • Default Gateway
  • Primary & Secondary DNS Addresses
  • DNS Suffix

Before I can run my PowerShell configuration scripts against the ESX, it has to have an IP address and hostname that can be resolved, otherwise my PowerShell scripts go somewhat "doolally". So for sometime I have been toying with dispensing with a static configuration, and using DHCP to configure the ESXi host.

Horrifying isn’t it? If you're from EMEA like me, the idea of giving an physical server a DHCP address is an unspoken taboo. You just DON’T create that kind of dependency between the physical server and the outside world. Interestingly, I stuck rigidly to this view until last year, when I was stopped in my tracks by PowerPoint slide which said “use DHCP to solve this problem”. I was aghast. You’ll never get that past anyone in EMEA, I said – some of them can’t even get approval for DHCP for PXE booting in a server room LAN. And I guess that for many that will remain the case. It seems this culture is perhaps different across the pond…

In a very informal poll of my U.S. chums, the issue of using DHCP to configure ESXi seemed to garner the response, if it works for you, what’s the problem – I do it here… Perhaps all these years I’ve

    Requires Free Membership to View

got stuck in a rut with DHCP?

So today, I thought I would experiment with reconfiguring the Linux DHCP service that runs in my UDA in my lab environment to lease a static “client-reservation” to my ESX host. I did that by adding:

host esx4 {
option host-name “esx4″;
option domain-name “vi4book.com”;
option routers,;
option domain-name-servers,;
hardware ethernet 00:15:60:AC:E4:40;

I got the MAC address of the ethernet card from the HP ILO. Then I did a factory reset of the ESXi host, which left me with just the root password to setup on boot-up. Everything now is done by combination of DHCP with PowerShell.

This was first published in August 2009

There are Comments. Add yours.

TIP: Want to include a code block in your comment? Use <pre> or <code> tags around the desired text. Ex: <code>insert code</code>

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
Sort by: OldestNewest

Forgot Password?

No problem! Submit your e-mail address below. We'll send you an email containing your password.

Your password has been sent to:

Disclaimer: Our Tips Exchange is a forum for you to share technical advice and expertise with your peers and to learn from other enterprise IT professionals. TechTarget provides the infrastructure to facilitate this sharing of information. However, we cannot guarantee the accuracy or validity of the material submitted. You agree that your use of the Ask The Expert services and your reliance on any questions, answers, information or other materials received through this Web site is at your own risk.