Understanding DHCP Fundamentals

This basic guide explains how Dynamic Host Configuration Protocol works and optional DHCP functionality.

Network Computing logo

Dynamic Host Configuration Protocol (DHCP) plays a critical role in how users communicate on enterprise networks. Understanding DHCP capabilities and features is an essential skill that every network administrator must have. This article explains the core aspects of DHCP and optional functionality with the technology.

The overall goal of DHCP is to simplify the configuration and management of IP addresses allocated to end-user devices such as desktops, laptops, and wireless clients. When an end device is configured to dynamically learn its IP address from a DHCP server, three pieces of information are absolutely necessary: IP address, subnet mask, and default gateway.

The IP address is the individual and unique address that each device has while connected to a network. Configuring a DHCP server to hand out IP addresses on a subnet is known as a DHCP pool. This pool of addresses is usually a range of consecutive numbers within a single IP subnet. Any numbers that the administrator does not want to have handed out can be excluded from the pool. The subnet mask tells devices how large the subnetwork is that they are connected to; this is critical from a broadcast perspective. Finally, the default gateway is the IP address that signifies "the way out" of the subnetwork to which the device belongs.

DNS and more

Technically, IP address, subnet mask, and default gateway are all that's required to get a device up and connected to the network from pure IP perspective. However, when we communicate with other devices and servers on an IP network, we typically don't connect directly to an IP address. Instead, we use domain names and DNS servers, which map an IP address with an easier-to-remember name. Client devices must know where their DNS servers reside so they can access the name-to-IP database. While it's possible to configure DNS server IP address locations statically, this information is commonly sent within the DHCP request process.

Just as the DHCP server can provide information for DNS servers, the server can also be configured to pass along information for other server resources. For example, many enterprise IP phones pull their configuration information from a server on the network. DHCP option 150 is often configured and enabled to inform IP phones where to download the configuration files. Other common DHCP options include option 42 to identify the location of Network Time Protocol (NTP) servers and option 7, which specifies the location of logging servers.



In most cases, DHCP will work with default settings that are largely are the same from server to server. One setting that does vary from one DHCP server type to the next-- and one that sometimes should be altered -- is the DHCP lease timer. On many servers, the default DHCP lease time -- the time that a device is allowed to hold onto a specific IP address -- is a week or longer. But in today's mobile environment, many administrators have found that their pool of available addresses can run out quickly.

To remedy this, DHCP lease times can be reduced to stay with a specific device for a few hours or less. The process of determining optimal DHCP lease times depends on the type of users, the size of your DHCP subnets, and how much load the DHCP server can handle.

DHCP relay agent

Another aspect of DHCP that's important to understand is that the protocol utilizes broadcasts from client to the server in order to find the DHCP server and initiate the request. But on very large networks with hundreds or thousands of different IP subnets, it would be impossible to maintain a DHCP server per subnet. This is where the concept of a DHCP relay agent comes into play.

A DHCP relay agent is a way for the network to listen to DHCP server discovery broadcast messages from client devices, convert broadcast requests into a unicast packet, and forward requests onto the DHCP server that's in a different part of the network. This centralizes the management of IP addresses on your network.

There are plenty of other parts of DHCP that network engineers need to understand, which are beyond the scope of this primer. Understanding DHCP is a key part of a network engineer’s toolset that's likely to come in handy on a daily basis.

About the Author(s)

Andrew Froehlich, President, West Gate Networks

President, West Gate Networks

As a highly experienced network architect and trusted IT consultant with worldwide contacts, particularly in the United States and Southeast Asia, Andrew Froehlich has nearly two decades of experience and possesses multiple industry certifications in the field of enterprise networking. Froehlich has participated in the design and maintenance of networks for State Farm Insurance, United Airlines, Chicago-area schools and the University of Chicago Medical Center. He is the founder and president of Loveland, Colo.-based West Gate Networks, which specializes in enterprise network architectures and data center build outs. The author of two Cisco certification study guides published by Sybex, he is a regular contributor to multiple enterprise IT related websites and trade journals with insights into rapidly changing developments in the IT industry.

Stay informed! Sign up to get expert advice and insight delivered direct to your inbox

You May Also Like

More Insights