When problems occur on a DHCP server, it is worth checking whether the server itself is functioning before assuming the DHCP configuration is at fault. Use standard Solaris commands to verify that the server is working, such as ping , ifconfig , and snoop . You can also stop and start the DHCP server process, in.dhcpd , as described in Chapter 11, "Basic DHCP." Doing this can often solve a number of problems, particularly when the process has hung and is not responding to client requests , or when you are using either the binary or nisplus format for the DHCP datastore, neither of which is human readable. Error MessagesThere are a number of reasons why a DHCP client might be unable to obtain an IP address from a DHCP server. Table 12.2 lists some of the more common errors encountered , along with a brief explanation of what the cause of the error is and also the required resolution. Note that the IP addresses will be different from those shown here. Table 12.2. Common DHCP Error Messages
Running the DHCP Server in Debug ModeIf there are problems with the DHCP server that cannot be easily resolved, it is useful to run the server process, in.dhcpd , in debug mode to receive additional messages on the server console. The following example shows the process running in debug mode, using the -d option, and also with verbose output, using the -v option. The lines of interest appear in bold. # /usr/lib/inet/in.dhcpd -d -v 3ef739e5: Daemon Version: 3.5 3ef739e5: Maximum relay hops: 4 3ef739e5: Run mode is: DHCP Server Mode. 3ef739e5: Datastore resource: SUNWfiles 3ef739e5: Location: /var/dhcp 3ef739e5: DHCP offer TTL: 10 3ef739e5: ICMP validation timeout: 1000 milliseconds, Attempts: 1. 3ef739e5: Name service update enabled, timeout: 15 seconds 3ef739e5: Maximum concurrent clients: 1024 3ef739e5: Maximum threads: 256 3ef739e5: Read 3 entries from DHCP macro database on Mon Jun 16 18:33:25 2003 3ef739e5: Monitor (0003/hme0) started... 3ef739e5: Thread Id: 0003 - Monitoring Interface: hme0 ***** 3ef739e5: MTU: 1500 Type: SOCKET 3ef739e5: Broadcast: 192.168.28.255 3ef739e5: Netmask: 255.255.255.0 3ef739e5: Address: 192.168.28.28 3ef73a71: Datagram received on network device: hme0 3ef73a71: Reserved offer: 192.168.28.32 3ef73a72: Unicasting datagram to 192.168.28.32 address. 3ef73a72: Adding ARP entry: 192.168.28.32 == 0800208E48CE 3ef73a72: Updated offer: 192.168.28.32 3ef73a73: Datagram received on network device: hme0 3ef73a73: Client: 010800208E48CE maps to IP: 192.168.28.32 3ef73a73: Unicasting datagram to 192.168.28.32 address. 3ef73a73: Adding ARP entry: 192.168.28.32 == 0800208E48CE The lines in bold show the messages received when a DHCP client requests an IP address. In this case, the IP address allocation worked because the client was mapped to the IP address successfully. Later on, when the client is shut down, the debug output shows the same IP address being released: 3ef73b2d: Freeing offer: 192.168.28.32 3ef73b2d: Datagram received on network device: hme0 3ef73b2d: Client: 010800208E48CE RELEASED address: 192.168.28.32 3ef73b2d: RELEASE: client message: DHCP agent is exiting |