Setting Up a DHCP Server

[Previous] [Next]

The DHCP server greatly reduces the administrative task of configuring workstations with an IP address and the appropriate TCP/IP settings for your network. Before installing the DHCP server, determine your IP addressing scheme. (See Chapter 12.) You must also complete these additional steps before installing DHCP:

  • Determine the range of unique, free IP addresses that your DHCP server will manage as well as any IP addresses that need to be excluded to support hosts with static IP addresses.
  • Make a list of servers that you want to give IP reservations to (such as DNS and WINS servers).
  • If your DHCP server will be using Internet-registered IP addresses, register your IP addresses with your ISP.
  • Upgrade any Windows NT 4 domain controllers to Windows 2000.
  • Determine the hardware and storage requirements for the DHCP server.
  • Manually configure the static IP address on the computer where DHCP service are to be installed.

To install the DHCP service, follow these steps:

  1. Open the Configure Your Server tool (if it's not already open) by launching it from the Administrative Tools folder.
  2. Click the Networking heading in the column on the left, and then click the DHCP subheading.
  3. Click the Start hyperlink (shown in Figure 6-14) to launch the Windows Components Wizard.
  4. click to view at full size.

    Figure 6-14. Setting up DHCP using the Configure Your Server tool.

  5. Click Next in the first screen of the Windows Component Wizard.
  6. Select Networking Services from the list of components, and then click Details.
  7. Select the check box next to the Dynamic Host Configuration Protocol (DHCP) component, and click OK. Click Next to install the service. All the necessary files are copied to your hard disk.

TIP
If you want to install DHCP service on a server that isn't a domain controller, you'll need to tell Active Directory about it. After installation, open DHCP from the Administrative Tools menu. Highlight DHCP in the console tree, and then choose Browse Authorized Servers from the Action menu. Click Add, and then type in the name or IP address of the DHCP server to authorize.

REAL WORLD   Using Multiple DHCP Servers
If you plan to use multiple DHCP servers on a subnet for load-balancing and redundancy, configure a superscope on each DHCP server that contains all valid scopes for the subnet as member scopes. Then configure a member scope on each server that has the other servers' addresses excluded so that no addresses appear in both servers' address pools. A good division is to give 80 percent of the addresses to the primary DHCP server and 20 percent to the secondary server.

Creating a New Scope

Now you're ready to launch the DHCP Manager and create a new scope of IP addresses for the DHCP server to manage. But before you can do this, make sure you know which range of IP addresses are approved, which IP addresses need to be excluded for systems with static IP addresses, and which IP addresses need to be reserved for DNS or WINS servers. To open DHCP Manager and create your new scope, follow these steps:

  1. Choose DHCP from the Administrative Tools menu.
  2. Select the DHCP server in the console tree. Select the Action menu and choose New Scope to launch the Create Scope Wizard.
  3. Click Next, and enter a name and description for the scope to use for distinguishing this scope from others (Figure 6-15). Click Next.
  4. Enter the IP address that your scope begins with in the Start field, and enter the IP address that your scope ends with in the End field, as shown in Figure 6-16.
  5. click to view at full size.

    Figure 6-15. The Scope Name screen of the New Scope Wizard.

    click to view at full size.

    Figure 6-16. The IP Address Range screen of the New Scope Wizard.

  6. Enter your network's subnet mask in the Mask box, or use the Length box to adjust the length of your subnet mask. Then click Next.

MORE INFO
A good source of information on the complex subject of choosing subnet masks is the book Microsoft TCP/IP Training (Microsoft Press, 1997).

  1. To exclude a range of addresses from your scope, in the Start IP Address box, enter the start IP address for the exclusion range; in the End IP Address box, enter the end IP address for the exclusion range. Then click Add. Add as many exclusions as needed, and click Next when you're finished.
  2. Specify the lease duration for your clients, and then click Next.

REAL WORLD   Setting Lease Durations
Use longer leases for networks without redundant DHCP servers to permit more time to recover an offline DHCP server before clients lose their leases, or to minimize network traffic at the expense of less frequent address turnover. You can also use longer leases if scope addresses are plentiful (at least 20 percent available), the network is stable, and computers are rarely moved about. In contrast, scopes that support dial-up clients can have shorter leases and therefore function well with fewer addresses.

  1. To configure DHCP options, select click Yes; otherwise, click No, and then click Next. If you select No, click Finish to complete the setup of your scope.
  2. If you chose to specify DHCP options, enter the gateways (routers) you want clients to use in the Gateway Address box, clicking the Add button after entering each one. When you're finished adding gateways, click Next.
  3. Enter the domain name of your domain in the Parent Domain box, and add the IP addresses for your DNS servers in the IP Address box, as shown in Figure 6-17, clicking Add after entering each one. Click Next when you're done.
  4. In the WINS Server Address box, enter the addresses of any WINS servers you've configured on your network for resolving NetBIOS names into IP addresses for downlevel clients. Click Next.
  5. To activate the scope immediately, click Yes; otherwise, click No to activate the scope later. Click Next, and then click Finish to complete your scope configuration.

click to view at full size.

Figure 6-17. The Domain Name And DNS Servers screen of the New Scope Wizard.

Authorizing the DHCP Server and Activating Scopes

After you've set up your DHCP server and created the scopes, you need to activate the scopes before any clients can use the server to obtain an IP address. Before scopes can be activated, the server has to be authorized to give leases, unless you installed DHCP on a domain controller, in which case the DHCP server will be authorized automatically the first time you add the server to your DHCP Manager console. Authorizing a DHCP server is an important option that Windows 2000 provides to reduce the ability of hackers to set up rogue DHCP servers—unauthorized servers set up to hand out false IP addresses to clients. To authorize your DHCP server after installing the service, follow these steps:

  1. In the DHCP Manager, select DHCP at the root of the console tree.
  2. Choose Manage Authorized Servers from the Action menu.
  3. Select Authorize in the Manage Authorized Servers dialog box.
  4. Enter the name or IP address for your server in the text box provided and click OK.
  5. Verify that the information is correct in the dialog box displayed, and then click Yes. Click OK to close the Manage Authorized Servers dialog box.
  6. To activate a scope, select the scope from the Console Tree, and then choose Activate from the Action menu.

Don't activate a scope until you've finished selecting all the options you want. Once you've activated a scope, the Activate command on the menu changes to Deactivate. Don't deactivate a scope unless it's being permanently retired from the network.

Adding Address Reservations

Reservations are handy items that you can use instead of static IP addresses (which require exclusions) for all servers (except DHCP servers) that need to maintain a specific IP address, such as DNS and WINS servers. Using reservations instead of static addresses guarantees that a server will have a consistent IP address while also providing the ability to recover the IP address in the future if the server is decommissioned or moved. You should create the reservation on all DHCP servers that could potentially service the reserved client. To add an address reservation to a scope, follow these steps:

  1. Right-click the Reservations folder under the desired scope, and choose New Reservation from the shortcut menu.
  2. Enter a name for the reservation in the Reservation Name box.
  3. Enter the IP address for the client in the IP address box, and enter the MAC address for the client in the MAC Address box, as shown in Figure 6-18.
  4. Figure 6-18. The New Reservation dialog box.

  5. Enter a description for the reservation in the Description box.
  6. Determine which type of client you want to allow to use the reservation by selecting DHCP Only, BOOTP Only, or Both. Click Add.

NOTE
To obtain the MAC address, go to the client computer and type ipconfig /all at the command prompt. The MAC address is listed as the physical address.

Enabling Dynamic Updates to a DNS Server

The Windows 2000 DHCP and DNS servers now support dynamic updates to a DNS server—a feature that any administrator who has had to manage a static Windows NT 4 DNS server (or the like) will appreciate. Windows 2000 clients can dynamically update their forward lookup records themselves with the DNS server after obtaining a new IP address from a DHCP server.

In addition, the Windows 2000 DHCP server also supports dynamically updating the DNS records for pre–Windows 2000 clients that can't do it for themselves. This feature currently works only with the Windows 2000 DHCP and DNS servers. The Internet proposal for dynamic updates between DNS servers was in draft form during the creation of Windows 2000, but greater compatibility might be implemented soon after release. To enable a DHCP server to dynamically update the DNS records of its clients, follow these steps:

  1. Select the scope or DHCP server on which you want to permit dynamic DNS updates.
  2. From the Action menu, choose Properties, and then click the DNS tab.
  3. Select the Automatically Update DHCP Client Information In DNS check box, as shown in Figure 6-19.
  4. Figure 6-19. The DNS tab of the Main Scope Properties window.

  5. To update a client's DNS records based on the type of DHCP request the client makes and only when requested, select the Update DNS Only If DHCP Client Requests option.
  6. To always update a client's forward and reverse lookup records, select the Always Update DNS option.
  7. Select the Discard Forward Lookups When Leases Expire check box to have the DHCP server delete the Host resource record for a client when its DHCP lease expires and isn't renewed.
  8. Select the Enable Updates For DNS Clients That Do Not Support Dynamic Updates check box to enable the DHCP server to update the forward and reverse lookup records for clients that can't update their own forward lookup records. If you don't select this check box, the DHCP server won't automatically update the DNS records of non-Windows 2000 clients.

TIP
If you have static DNS servers such as those in Windows NT 4, these servers can't interact dynamically when DHCP client configurations are changed. This incompatibility can result in failed lookups for DHCP clients. To avoid this problem, upgrade static DNS servers with DNS that supports Dynamic DNS (Windows 2000).

Using Ipconfig to Release, Renew, or Verify a Lease

On a DHCP-enabled computer that's running Windows, you can run a command-line utility to release, renew, or verify the client's address lease. At a command prompt (or in the Run window), use one of the following commands:

  • To release a client's lease, type ipconfig/release
  • To renew a lease, type ipconfig/renew
  • To verify the client's lease, type ipconfig/all

For Windows 95/98 clients, use Winipcfg with the same parameters. The Ipconfig program is useful when troubleshooting problems because it displays every detail of the current TCP/IP configuration. You can find more troubleshooting information in Chapter 37.



Microsoft Windows 2000 Server Administrator's Companion, Vol. 1
Microsoft Windows 2000 Server Administrators Companion (IT-Administrators Companion)
ISBN: 1572318198
EAN: 2147483647
Year: 2000
Pages: 366

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net