Implementing and Understanding DHCPby Chris Sanders
The Dynamic Host Configuration Protocol (DHCP) is a member of the TCP/IP suite and a protocol that is designed to save network administrators a lot of time and effort. A successful DHCP implementation can do just that.
As you probably already know, every computer that communicates on a network does so via an IP (layer 4) address. The goal of DHCP is to provide a mechanism of automated address delivery, to give every computer its own IP address without an administrator having to type them all in manually. In small networks, this isn't too big of an issue. However, in networks with tens, hundreds, and even thousands of computers, the task of IP address management is daunting. Luckily, Windows Server 2003 provides a means for us to implement DHCP with its own DHCP server service (see Figure 1).
Figure 1. DHCP Servers assign computers IP addresses from a user-specified range
Planning for DHCP
The first stage to any technical implementation is planning. Here are a few key things to consider when thinking about DHCP:
- Addresses to distribute: DHCP is not only capable of distributing IP addresses and subnet masks, but also default gateways, DNS server addresses, and WINS server addresses. Depending on the layout of your network, you may choose to use DHCP for all of these or only some.
- Network layout: In most common cases, networks are confined to a single LAN within one building or location. In these cases, a single DHCP server for the organization will do (or two servers for failover's sake). In some networks, however, you will begin dealing with a large WAN containing multiple individual locations. Depending on the connections between these points and the number of clients and each location, you may need to consider having multiple DHCP servers set up to handle the distribution of addresses.
- Addressing scheme: Every network has its own unique addressing scheme. That being the case, you should be familiar with your network's scheme. This includes the IP addresses used and how they are subnetted. Subnetting is beyond the scope of this article, but it will determine which groups of IP addresses you can have your DHCP server hand out.
- Lease duration: When a computer requests an IP address from a DHCP server, the IP address it receives is set up on a lease. This means that this particular computer is assigned this IP address for a certain amount of time before it must request a new one from the server. Depending on the nature of the work being done on your network, you may need these addresses to be leased for a longer or shorter period of time than the default. Also, the makeup of the clients on your network should be taken into consideration. For example, if your network consists mostly of portable clients that connect and disconnect from the network often, you will want to use shorter lease times.
- Static assignments: Although the bulk of network clients can be handled with dynamically assigned IP addresses, there will always be some that require static assignments. You will often see this with routers, switches, servers, and any other managed administrative devices. If a range of IP addresses is being handed out to clients by a DHCP server that includes a statically assigned IP address, then the chance of IP conflicts arises. This occurs when two devices are assigned the same IP address, and it causes both of them to be unable to access the network.
The DHCP server service is built into the Windows Server 2003, and can be installed during the initial operating system installation or afterward from the Configure Your Server wizard. We will assume you are installing DHCP on a pre-existing Windows Server 2003 machine.
Begin by accessing the Configure Your Server dialog, either as it appears when you first log in or from the control panel. In this window, select "DHCP Server" from the list of server roles and click "Next." This begins the installation process by bringing up the New Scope Wizard. A scope is a range of IP addresses configured on a DHCP server. In this scenario we will configure a scope of IP addresses for our DHCP server to hand out to the sales department of our example company. As you can see in Figure 2, the first screen of this wizard is where you create a name of this scope. Coming up with a descriptive naming scheme for your DHCP scopes is crucial, especially if you are setting up several scopes on one server. After entering the name and description for your scope, click "Next."
Figure 2. Creating a name and description for a DHCP scope
The following screen will prompt you for the addressing information of the scope (Figure 3); that is, the range of IP addresses to be distributed and the subnet mask the network is configured for. As stated earlier, calculating subnets is a little beyond the scope of this article, but this is something you should consider and plan out well before actually setting up your DHCP server.
Figure 3. Configuring the IP addresses to be handed out by this DHCP scope
Pages: 1, 2