[Home]

DHCP Trivia


DHCP can be used to allocate IP addresses automatically to PC's connecting to the server.

This is ideal where you may have a member of staff who 'floats' between mutiple sites and needs to take a laptop with them and sites have different IP address ranges. Also when TCP/IP is initially configured on a PC it will default to 'Obtain an IP address automatically' - which saves having to talk a user through manually setting the IP details. Just plug in and go.

This also has the advantage that most if the Windows setup is handled by a central location and not all over the place.

OpenServer has two 'managers' to configure DHCP:

I have found using the CHARM version of the AAS and DHCP managers to be a little troublesome (the X version works fine) so I will show the examples from the config files. If you do change the config files manually remember to send a SIGHUP signal (kill -1) to the process to allow it to re-read the configureation files. Check the man pages for aasd and dhcpd for details of starting them - if the files exist they will be restarted automatically when the system starts up.

This guide shows adding a few PC's to an existing network and covers just the basics.

Running both AAS/DHCP managers will generate two files:

Once the initial setup is done the PC's will be allocated an IP address and will work as normal. You can use the Windows (98/ME) utility 'winipcfg' to show you the current setting and request new addresses as needed.

More on DHCP

Static addresses

Some application use the 'location' or 'IP address' of the PC to set various defaults this at first glance may give a problem. What can you do?

Use DHCP to assign a fixed address based on hardware address.

In this situation, everytime the PC is connected to the main server it will be given a fixed address

Run winipcfg on the Windows PC to obtain the MAC address (Adapter Address) and enter this as a 'client' in the DHCP server Manager - Note - the address you give it must NOT be one allocated by AAS.

This should add an entry into /etc/dhcpd.conf as per:

client 01 00008637F1DE {
	comment Tom's Laptop
	ip_address 192.168.10.77
}

Now when that PC connects it will always be given the IP address 192.168.10.77

Unknown Vendor Class

Newsgroups: comp.unix.sco.misc
From: Roger Cornelius 
Subject: Re: DHCP unknown vendor class error repeated 100's of times
Date: Sun, 27 May 2001 01:07:57 GMT

Gary Quiring wrote: > > I'm running SCO 506 without the rs506a patch. The DHCP server went > nuts this weekend with "ping sendto failed messages" in syslog. Those > errors have stopped, but the "unknown vendor class" error continues. > > The DHCP server is working fine, I'm just curious what the vendor > error means and can I narrow down what is causing it?

[...]

>May 14 17:49:12 emco11 dhcpd[29665]: Unknown vendor class 0x4d534654203938

If you convert the mentioned vendor class into ASCII, you'll get "MSFT 98". Add the following to /etc/dhcpd.conf and the messages will stop.

vendor_class "MSFT 98" { comment to shut dhcpd up }

(In a similar fashion: 0x4d53465420352e30 is MSFT 5.0)

What is going on?

One of the simplist ways is to switch 'debugging' on for both aas and dhcp and look in /usr/adm/syslog.

Look in /usr/adm/syslog and you should see various lines as per:

This shows a PC being allocated a static address:

Jun  1 10:45:01 xanth aasd[12844]: Address Allocation Server starting.
Jun  1 10:45:01 xanth aasd[12844]: Pool ippool, type INET
Jun  1 10:45:01 xanth aasd[12844]: Configuration complete; ready.
Jun  1 10:45:01 xanth aasd[12844]: Checkpointing.
Jun  1 10:46:05 xanth dhcpd[12849]: connect from 0.0.0.0
Jun  1 10:46:05 xanth dhcpd[12849]: Starting.
Jun  1 10:46:05 xanth dhcpd[12849]: Req: IF 192.168.10.1 XID 0xe040e04 client HW 1:00008637f1de
Jun  1 10:46:05 xanth dhcpd[12849]:   Message type: 3
Jun  1 10:46:05 xanth dhcpd[12849]:   Client ID: 0x0100008637f1de
Jun  1 10:46:05 xanth dhcpd[12849]:   Requested address: 192.168.10.77
Jun  1 10:46:05 xanth dhcpd[12849]:   Parameter request list: 0x0103060f2c2e2f39
Jun  1 10:46:05 xanth dhcpd[12849]: Found client in database.
Jun  1 10:46:05 xanth dhcpd[12849]: Request matches subnet 192.168.10.0
Jun  1 10:46:05 xanth dhcpd[12849]: Request is DHCPREQUEST.
Jun  1 10:46:05 xanth dhcpd[12849]: Sending DHCPACK: address 192.168.10.77 lease 4294967295
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 53: 0x05
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 54: 0xc0a80a01
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 51: 0xffffffff
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 1: 0xffffff00
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 3: 0xc0a80a01
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 6: 0xc0a80a01
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 15: 0x746b72682e64656d6f6e2e636f2e756b
Jun  1 10:46:05 xanth dhcpd[12849]: Stored option 69: 0xc0a80a01
Jun  1 10:46:05 xanth dhcpd[12849]: Sending reply to 192.168.10.77

This shows the same PC connecting but without the 'client' comment in the config file so this is being allocated a dynamic address.

Jun  1 10:51:23 xanth dhcpd[12860]: Req: IF 192.168.10.1 XID 0x2e9f2e9f client HW 1:00008637f1de
Jun  1 10:51:23 xanth dhcpd[12860]:   Message type: 1
Jun  1 10:51:23 xanth dhcpd[12860]:   Client ID: 0x0100008637f1de
Jun  1 10:51:23 xanth dhcpd[12860]:   Requested address: 192.168.10.120
Jun  1 10:51:23 xanth dhcpd[12860]:   Parameter request list: 0x0103060f2c2e2f39
Jun  1 10:51:23 xanth dhcpd[12860]: Request matches subnet 192.168.10.0
Jun  1 10:51:23 xanth dhcpd[12860]: Request is DHCPDISCOVER.
Jun  1 10:51:23 xanth aasd[12844]: Received message from unix:: type 6, length 55
Jun  1 10:51:23 xanth aasd[12844]: Received CLIENT_QUERY_REQ
Jun  1 10:51:23 xanth aasd[12844]: Received message from unix:: type 0, length 79
Jun  1 10:51:23 xanth aasd[12844]: Received ALLOC_REQ
Jun  1 10:51:23 xanth aasd[12844]: ALLOC_REQ pool ippool (type 1) flags 0x6 lease 180 service DHCP client c0a80a000100008637f1de
Jun  1 10:51:23 xanth aasd[12844]:     req addr 192.168.10.120
Jun  1 10:51:23 xanth aasd[12844]:     min addr 192.168.10.1
Jun  1 10:51:23 xanth aasd[12844]:     max addr 192.168.10.254
Jun  1 10:51:23 xanth aasd[12844]: Allocating 192.168.10.120
Jun  1 10:51:23 xanth dhcpd[12860]: Pinging 192.168.10.120
Jun  1 10:51:24 xanth dhcpd[12860]: Ping timed out.
Jun  1 10:51:24 xanth dhcpd[12860]: Sending DHCPOFFER: address 192.168.10.120 lease 3600
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 53: 0x02
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 54: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 51: 0x00000e10
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 58: 0x00000a8c
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 59: 0x00000ca8
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 1: 0xffffff00
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 3: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 6: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 15: 0x746b72682e64656d6f6e2e636f2e756b
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 69: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Sending reply to 192.168.10.120
Jun  1 10:51:24 xanth dhcpd[12860]: Req: IF 192.168.10.1 XID 0x2e9f2e9f client HW 1:00008637f1de
Jun  1 10:51:24 xanth dhcpd[12860]:   Message type: 3
Jun  1 10:51:24 xanth dhcpd[12860]:   Client ID: 0x0100008637f1de
Jun  1 10:51:24 xanth dhcpd[12860]:   Requested address: 192.168.10.120
Jun  1 10:51:24 xanth dhcpd[12860]:   Server ID: 192.168.10.1
Jun  1 10:51:24 xanth dhcpd[12860]:   Parameter request list: 0x0103060f2c2e2f39
Jun  1 10:51:24 xanth dhcpd[12860]: Request matches subnet 192.168.10.0
Jun  1 10:51:24 xanth dhcpd[12860]: Request is DHCPREQUEST.
Jun  1 10:51:24 xanth aasd[12844]: Received message from unix:: type 0, length 71
Jun  1 10:51:24 xanth aasd[12844]: Received ALLOC_REQ
Jun  1 10:51:24 xanth aasd[12844]: ALLOC_REQ pool ippool (type 1) flags 0x1 lease 3636 service DHCP client c0a80a000100008637f1de
Jun  1 10:51:24 xanth aasd[12844]:     req addr 192.168.10.120
Jun  1 10:51:24 xanth aasd[12844]: Allocating 192.168.10.120
Jun  1 10:51:24 xanth dhcpd[12860]: Sending DHCPACK: address 192.168.10.120 lease 3600
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 53: 0x05
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 54: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 51: 0x00000e10
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 58: 0x00000a8c
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 59: 0x00000ca8
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 1: 0xffffff00
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 3: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 6: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 15: 0x746b72682e64656d6f6e2e636f2e756b
Jun  1 10:51:24 xanth dhcpd[12860]: Stored option 69: 0xc0a80a01
Jun  1 10:51:24 xanth dhcpd[12860]: Sending reply to 192.168.10.120


Comments and suggestions always welcome - tom@tkrh.demon.co.uk