diff -rNc2 DHCPD-BETA-5.16/Makefile.dist DHCPD-BETA-5.17/Makefile.dist *** DHCPD-BETA-5.16/Makefile.dist Fri May 9 01:44:13 1997 --- DHCPD-BETA-5.17/Makefile.dist Sat Nov 29 00:00:22 1997 *************** *** 1,5 **** # Makefile.dist # ! # Copyright (c) 1996 The Internet Software Consortium. All rights reserved. # # Redistribution and use in source and binary forms, with or without --- 1,6 ---- # Makefile.dist # ! # Copyright (c) 1996, 1997 The Internet Software Consortium. ! # All rights reserved. # # Redistribution and use in source and binary forms, with or without *************** *** 39,43 **** MANINSTALL = install CHMOD = chmod ! CATMANPAGES = dhcpd.cat8 dhcpd.conf.cat5 ETC = /etc VARRUN = /var/run --- 40,44 ---- MANINSTALL = install CHMOD = chmod ! CATMANPAGES = dhcpd.cat8 dhcpd.conf.cat5 dhcpd.leases.cat5 ETC = /etc VARRUN = /var/run *************** *** 197,201 **** OBJS = dhcpd.o dhcp.o bootp.o conflex.o confpars.o db.o PROG = dhcpd dhcpxlt ! MAN = dhcpd.8 dhcpd.conf.5 DEBUG = -g --- 198,202 ---- OBJS = dhcpd.o dhcp.o bootp.o conflex.o confpars.o db.o PROG = dhcpd dhcpxlt ! MAN = dhcpd.8 dhcpd.conf.5 dhcpd.leases.5 DEBUG = -g *************** *** 222,225 **** --- 223,229 ---- $(MANINSTALL) $(MANFROM) dhcpd.conf.cat5 $(MANTO) \ $(FFMANDIR)/dhcpd.conf$(FFMANEXT) + $(MANINSTALL) $(MANFROM) dhcpd.leases.cat5 $(MANTO) \ + $(FFMANDIR)/dhcpd.leases$(FFMANEXT) + clean: *************** *** 237,243 **** dhcpd.cat8: dhcpd.8 ! sed -e "s#ETCDIR#$(ETC)#" -e "s#DBDIR#$(VARDB)#" \ ! -e "s#RUNDIR#$(VARRUN)#" < dhcpd.8 \ | nroff -man >dhcpd.cat8 dhcpd.conf.cat5: dhcpd.conf.5 --- 241,252 ---- dhcpd.cat8: dhcpd.8 ! sed -e "s#ETCDIR#$(ETC)#g" -e "s#DBDIR#$(VARDB)#g" \ ! -e "s#RUNDIR#$(VARRUN)#g" < dhcpd.8 \ | nroff -man >dhcpd.cat8 + + dhcpd.leases.cat5: dhcpd.leases.5 + sed -e "s#ETCDIR#$(ETC)#g" -e "s#DBDIR#$(VARDB)#g" \ + -e "s#RUNDIR#$(VARRUN)#g" < dhcpd.leases.5 \ + | nroff -man >dhcpd.leases.cat5 dhcpd.conf.cat5: dhcpd.conf.5 diff -rNc2 DHCPD-BETA-5.16/README DHCPD-BETA-5.17/README *** DHCPD-BETA-5.16/README Fri May 9 00:38:07 1997 --- DHCPD-BETA-5.17/README Tue Dec 2 01:36:23 1997 *************** *** 10,16 **** well on Digital Alpha OSF/1, SunOS 4.1.4, NetBSD, FreeBSD, BSD/OS and Ultrix. It can also be run usefully on Solaris as long as only one ! network interface is being used. It also runs on QNX and Linux as ! long as only one network interface is present and a host route is ! added from that interface to the 255.255.255.255 broadcast address. If you wish to run dhcpd on Linux, please see the Linux-specific notes --- 10,17 ---- well on Digital Alpha OSF/1, SunOS 4.1.4, NetBSD, FreeBSD, BSD/OS and Ultrix. It can also be run usefully on Solaris as long as only one ! broadcast network interface is configured. It also runs on QNX and ! Linux as long as only one broadcast network interface is configured ! and a host route is added from that interface to the 255.255.255.255 ! broadcast address. If you wish to run dhcpd on Linux, please see the Linux-specific notes *************** *** 19,24 **** need to read these notes if you intend to support Windows 95 clients. If you are running a version of FreeBSD prior to 2.2, please read the ! note on FreeBSD. If you are running HP-UX or Ultrix, please read the ! notes for those operating systems below. BUILDING DHCPD --- 20,25 ---- need to read these notes if you intend to support Windows 95 clients. If you are running a version of FreeBSD prior to 2.2, please read the ! note on FreeBSD. If you are running HP-UX, Ultrix or Digital UNIX, ! please read the notes for those operating systems below. BUILDING DHCPD *************** *** 38,41 **** --- 39,54 ---- LINUX + There are two big LINUX issues: Linux 2.1 ip_bootp_agent enabling and + the all-ones broadcast address. + + BOOTP AGENT ENABLING + + Also, some versions of the Linux 2.1 kernel apparently prevent dhcpd + from working unless you enable it by doing the following: + + echo 1 >/proc/sys/net/ipv4/ip_bootp_agent + + BROADCAST + In order for dhcpd to work correctly with picky DHCP clients (e.g., Windows 95), it must be able to send packets with an IP destination *************** *** 49,54 **** It is possible to work around this problem on some versions of Linux by creating a host route from your network interface address to ! 255.255.255.255. The command you need to use to do this on Linux ! varies from version to version. The easiest version is: route add -host 255.255.255.255 dev eth0 --- 62,67 ---- It is possible to work around this problem on some versions of Linux by creating a host route from your network interface address to ! 255.255.255.255. The command you need to use to do this on Linux ! varies from version to version. The easiest version is: route add -host 255.255.255.255 dev eth0 *************** *** 91,99 **** HP-UX has the same problem with the all-ones broadcast address that ! SCO and Linux have. It is not entirely clear to me how to get it ! working on HP-UX, but I'm given to understand that some users have ! succeeded. HP-UX comes with its own DHCP server as of version 10, so ! there hasn't been a lot of interest in this recently. If you have ! trouble, ask on the mailing list. ULTRIX --- 104,117 ---- HP-UX has the same problem with the all-ones broadcast address that ! SCO and Linux have. One user reported that adding the following to ! /etc/rc.config.d/netconf helped (you may have to modify this to suit ! your local configuration): ! ! INTERFACE_NAME[0]=lan0 ! IP_ADDRESS[0]=1.1.1.1 ! SUBNET_MASK[0]=255.255.255.0 ! BROADCAST_ADDRESS[0]="255.255.255.255" ! LANCONFIG_ARGS[0]="ether" ! DHCP_ENABLE[0]=0 ULTRIX *************** *** 106,109 **** --- 124,134 ---- packet filter (if it isn't already) and how to make an entry for it in /dev. + + DIGITAL UNIX + + Digital Unix has one minor caveat - this version of the Internet + Software Consortium DHCP server cannot currently coexist with rarpd. + If you run dhcpd and rarpd together, dhcpd will never see any DHCP + requests, because the RARP filter has a higher priority. FreeBSD diff -rNc2 DHCPD-BETA-5.16/RELNOTES DHCPD-BETA-5.17/RELNOTES *** DHCPD-BETA-5.16/RELNOTES Sat Mar 29 01:36:39 1997 --- DHCPD-BETA-5.17/RELNOTES Tue Dec 2 01:54:54 1997 *************** *** 2,7 **** Dynamic Host Configuration Protocol Server Beta Release 5 ! Patchlevel 15 ! March 29, 1997 Release Notes --- 2,7 ---- Dynamic Host Configuration Protocol Server Beta Release 5 ! Patchlevel 17 ! December 2, 1997 Release Notes *************** *** 9,87 **** This patchlevel is on the Internet Software Consortium DHCP Server Release 1.0 track. The previous version was Beta Release 5, ! Patchlevel 14. This patchlevel is strictly a bug-fix patchlevel. ! The only new feature is Ultrix Packetfilter support, which is sufficiently ! far from the DHCP protocol engine that its inclusion was felt to be very ! low-risk. ! ! The following bug fixes have been made in this release: ! ! - When the server saw a DHCPREQUEST for a client that it knew had a ! lease on a different network, it would release that lease. This ! behaviour is incorrect according to the protocol - there is nothing ! in the protocol that says that a client can't simultaneously hold a ! lease on two addresses on two different networks. ! ! - On little-endian machines (e.g., intel machines and DEC machines), ! if a client requested that responses to it be broadcast rather than ! unicast, this request would not be honored because of a ! byte-swapping error. ! ! - The server would print a banner on startup and then go into a ! background (daemon) mode. If there was a parse error in the ! dhcpd.conf file, this was not detected until the server had gone ! into the background, and thus there was no immediate notification. ! This caused service failures for some users which were difficult to ! diagnose. Dhcpd now continues to log messages to the console until ! after it has successfully parsed the config file and lease file. ! Also, if dhcpd runs into a problem which causes it to exit, it now ! logs the message ``exited'' at CRITICAL priority, which should show ! up on the system console. ! ! - On Linux, spurious Host Unreachable and Connection Refused errors ! could delay or foil the DHCP protocol by preventing the transmission ! of some packets. This is because of a Linux kernel bug whereby ! bogus ICMP errors can be communicated to the user program. ! ! - DHCPNAK behaviour wasn't correct. In some cases, the server would ! not NAK DHCPREQUEST messages if they were on the wrong network. ! This has now been fixed. ! ! - DHCPACK behaviour was incorrect. If a client sent a DHCPREQUEST ! for an address that the server was not willing to provide, the ! server could respond with a DHCPACK for a different address, when it ! should have ignored the DHCPREQUEST. ! ! - DHCPDECLINE processing wasn't being done correctly, with the result ! that DHCPDECLINEs were effectively being ignored. DHCPDECLINEs are ! now processed correctly - leases which have been DECLINEed are ! abandoned and never again offered to clients, at lease until the ! administrator intervenes. Warning: this bug fix does open up the ! DHCP server to a denial of service attack that was formerly not ! possible - a client can successively request and DECLINE every lease ! in the server's database. ! ! - The lease file was being rewritten twice whenever it was time to ! rewrite it. This no longer happens. ! ! - BOOTP clients for which there was a host entry with no fixed-address ! would not be allowed to boot if the dynamic-bootp flag and the ! boot-unknown-clients flags were set. ! ! - If an address range specified within a subnet declaration was on the ! wrong network, dhcpd would silently mask off the erroneous network ! number and mask in the network number from the subnet declaration, ! resulting in incorrect and potentially harmful behaviour. Dhcpd ! now flags this as an error. ! ! - The vendor-encapsulated-options option was specified as a text ! string, which was incorrect. It is now specified as an arbitrary ! string of hexadecimal values, so that a user may mock up vendor ! tags. This behaviour will eventually be superseded by correct ! vendor option support. ! ! - On Ultrix, the executable was not being installed in the correct ! directory. ! ! - Got rid of change warnings in the configure script - these warnings ! were instituted in August of 1996, and probably anybody who would be ! affected by them is already aware of them. --- 9,57 ---- This patchlevel is on the Internet Software Consortium DHCP Server Release 1.0 track. The previous version was Beta Release 5, ! Patchlevel 16. This patchlevel is strictly a bug-fix patchlevel. ! Unlike Patchlevel 16, this patchlevel has some somewhat risky bug ! fixes, so please do not install it in a production environment. ! ! The following changes have been made in this release: ! ! - Added a man page for dhcpd.leases. ! ! - Updated README to answer some frequently asked questions. ! ! - Fixed a compile problem on Solaris 2.6. ! ! - Support interface aliases on Solaris. ! ! - Print day and month with leading zero in lease files if less than ! ten, for easier parsing by perl/sed/awk scripts. ! ! - Never make the lease database world writable, even if dhcpd is ! invoked with a bogus umask. ! ! - Fix DHCPRELEASE handling (before, addressed would never be ! released.) ! ! - If there is more than one lease for a particular client on a ! particular network, find the lease the client is asking for so as to ! avoid a cycle of NAKs. ! ! - If a BOOTP request is received from a particular client and that ! client has previously received a DHCP address, make sure that we ! still find a valid BOOTP lease so that we don't cycle through ! addresses. ! ! - Remove server-identifier option from documentation, other than to ! document that it has been deprecated. ! ! - Don't give up if we get an EINTR or EAGAIN while polling or ! selecting - these return statuses can occur spuriously without ! indicating a fatal problem. ! ! - Do not select for exceptions, since we don't handle them. This was ! causing massive CPU consumption on some systems. ! ! - When a DHCP client has been assigned a fixed address but had ! previously had a lease, it will request the old leased address. In ! such an event, send a DHCPNAK so that it will discover its new ! static binding. ! diff -rNc2 DHCPD-BETA-5.16/cf/sunos5-5.h DHCPD-BETA-5.17/cf/sunos5-5.h *** DHCPD-BETA-5.16/cf/sunos5-5.h Tue Sep 10 22:53:58 1996 --- DHCPD-BETA-5.17/cf/sunos5-5.h Sat Nov 29 00:05:57 1997 *************** *** 71,74 **** --- 71,80 ---- #include + /* Solaris 2.6 defines AF_LINK, so we need the rest of the baggage that + comes with it, but of course Solaris 2.5 and previous do not. */ + #if defined (AF_LINK) + #include + #endif + /* * Definitions for IP type of service (ip_tos) *************** *** 111,114 **** --- 117,121 ---- #define USE_POLL + #define ALIAS_NAMES_PERMUTED #define EOL '\n' *************** *** 123,124 **** --- 130,132 ---- #define random() rand() + diff -rNc2 DHCPD-BETA-5.16/db.c DHCPD-BETA-5.17/db.c *** DHCPD-BETA-5.16/db.c Sat Mar 29 00:06:45 1997 --- DHCPD-BETA-5.17/db.c Tue Dec 2 01:30:38 1997 *************** *** 43,47 **** #ifndef lint static char copyright[] = ! "$Id: db.c,v 1.8.2.1 1997/03/29 08:06:45 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ --- 43,47 ---- #ifndef lint static char copyright[] = ! "$Id: db.c,v 1.8.2.3 1997/12/02 09:30:38 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ *************** *** 72,76 **** t = gmtime (&lease -> starts); ! sprintf (tbuf, "%d %d/%d/%d %02d:%02d:%02d;", t -> tm_wday, t -> tm_year + 1900, t -> tm_mon + 1, t -> tm_mday, --- 72,76 ---- t = gmtime (&lease -> starts); ! sprintf (tbuf, "%d %d/%02d/%02d %02d:%02d:%02d;", t -> tm_wday, t -> tm_year + 1900, t -> tm_mon + 1, t -> tm_mday, *************** *** 83,87 **** t = gmtime (&lease -> ends); ! sprintf (tbuf, "%d %d/%d/%d %02d:%02d:%02d;", t -> tm_wday, t -> tm_year + 1900, t -> tm_mon + 1, t -> tm_mday, --- 83,87 ---- t = gmtime (&lease -> ends); ! sprintf (tbuf, "%d %d/%02d/%02d %02d:%02d:%02d;", t -> tm_wday, t -> tm_year + 1900, t -> tm_mon + 1, t -> tm_mday, *************** *** 186,189 **** --- 186,190 ---- char backfname [512]; TIME t; + int db_fd; /* If we already have an open database, close it. */ *************** *** 195,200 **** GET_TIME (&t); sprintf (newfname, "%s.%d", path_dhcpd_db, (int)t); ! if ((db_file = fopen (newfname, "w")) == NULL) { ! error ("Can't start new lease file: %m"); } --- 196,205 ---- GET_TIME (&t); sprintf (newfname, "%s.%d", path_dhcpd_db, (int)t); ! db_fd = open (newfname, O_WRONLY | O_TRUNC | O_CREAT, 0664); ! if (db_fd < 0) { ! error ("Can't create new lease file: %m"); ! } ! if ((db_file = fdopen (db_fd, "w")) == NULL) { ! error ("Can't fdopen new lease file!"); } diff -rNc2 DHCPD-BETA-5.16/dhcp.c DHCPD-BETA-5.17/dhcp.c *** DHCPD-BETA-5.16/dhcp.c Thu May 8 23:43:59 1997 --- DHCPD-BETA-5.17/dhcp.c Tue Dec 2 01:32:12 1997 *************** *** 43,47 **** #ifndef lint static char copyright[] = ! "$Id: dhcp.c,v 1.34.2.3 1997/05/09 06:43:59 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ --- 43,47 ---- #ifndef lint static char copyright[] = ! "$Id: dhcp.c,v 1.34.2.6 1997/12/02 09:32:12 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ *************** *** 284,290 **** struct packet *packet; { ! struct lease *lease = find_lease (packet, packet -> shared_network); ! note ("DHCPRELEASE of %s from %s via %s", inet_ntoa (packet -> raw -> ciaddr), print_hw_addr (packet -> raw -> htype, --- 284,319 ---- struct packet *packet; { ! struct lease *lease; ! struct iaddr cip; ! int i; ! ! /* DHCPRELEASE must not specify address in requested-address ! option, but old protocol specs weren't explicit about this, ! so let it go. */ ! if (packet -> options [DHO_DHCP_REQUESTED_ADDRESS].len) { ! note ("DHCPRELEASE from %s specified requested-address.", ! print_hw_addr (packet -> raw -> htype, ! packet -> raw -> hlen, ! packet -> raw -> chaddr)); ! } ! ! i = DHO_DHCP_CLIENT_IDENTIFIER; ! if (packet -> options [i].len) { ! lease = find_lease_by_uid (packet -> options [i].data, ! packet -> options [i].len); ! } else ! lease = (struct lease *)0; ! /* The client is supposed to pass a valid client-identifier, ! but the spec on this has changed historically, so try the ! IP address in ciaddr if the client-identifier fails. */ ! if (!lease) { ! cip.len = 4; ! memcpy (cip.iabuf, &packet -> raw -> ciaddr, 4); ! lease = find_lease_by_ip_addr (cip); ! } ! ! ! note ("DHCPRELEASE of %s from %s via %s (%sfound)", inet_ntoa (packet -> raw -> ciaddr), print_hw_addr (packet -> raw -> htype, *************** *** 293,298 **** packet -> raw -> giaddr.s_addr ? inet_ntoa (packet -> raw -> giaddr) ! : packet -> interface -> name); ! /* If we found a lease, release it. */ --- 322,327 ---- packet -> raw -> giaddr.s_addr ? inet_ntoa (packet -> raw -> giaddr) ! : packet -> interface -> name, ! lease ? "" : "not "); /* If we found a lease, release it. */ *************** *** 1009,1017 **** /* Find the lease that's on the network the packet came from (if any). */ ! for (; hw_lease; hw_lease = hw_lease -> n_hw) ! if (hw_lease -> shared_network == share) ! break; ! if (hw_lease && (hw_lease -> flags & ABANDONED_LEASE)) ! hw_lease = (struct lease *)0; /* Try to find a lease that's been allocated to the client's --- 1038,1052 ---- /* Find the lease that's on the network the packet came from (if any). */ ! for (; hw_lease; hw_lease = hw_lease -> n_hw) { ! if (hw_lease -> shared_network == share) { ! if (hw_lease -> flags & ABANDONED_LEASE) ! continue; ! if (packet -> packet_type) ! break; ! if (hw_lease -> flags & ! (BOOTP_LEASE | DYNAMIC_BOOTP_OK)) ! break; ! } ! } /* Try to find a lease that's been allocated to the client's *************** *** 1041,1046 **** if (ip_lease && ip_lease -> ends >= cur_time && ! ip_lease -> uid && ip_lease != uid_lease) ip_lease = (struct lease *)0; /* Toss hw_lease if it hasn't yet expired and the uid doesn't --- 1076,1099 ---- if (ip_lease && ip_lease -> ends >= cur_time && ! ip_lease -> uid && ip_lease != uid_lease) { ! int i = DHO_DHCP_CLIENT_IDENTIFIER; ! /* If for some reason the client has more than one lease ! on the subnet that matches its uid, pick the one that ! it asked for. It might be nice in some cases to ! release the extraneous leases, but better to leave ! that to a human. */ ! if (packet -> options [i].data && ! ip_lease -> uid_len == packet -> options [i].len && ! !memcmp (packet -> options [i].data, ! ip_lease -> uid, ip_lease -> uid_len)) { ! warn ("client %s has duplicate leases on %s", ! print_hw_addr (packet -> raw -> htype, ! packet -> raw -> hlen, ! packet -> raw -> chaddr), ! ip_lease -> shared_network -> name); ! uid_lease = ip_lease; ! } ip_lease = (struct lease *)0; + } /* Toss hw_lease if it hasn't yet expired and the uid doesn't *************** *** 1050,1056 **** if (hw_lease && hw_lease -> ends >= cur_time && ! hw_lease -> uid && hw_lease != uid_lease && ! (packet -> packet_type != 0 || ! !(hw_lease -> flags & DYNAMIC_BOOTP_OK))) hw_lease = (struct lease *)0; --- 1103,1109 ---- if (hw_lease && hw_lease -> ends >= cur_time && ! hw_lease -> uid && ! packet -> options [DHO_DHCP_CLIENT_IDENTIFIER].len && ! hw_lease != uid_lease) hw_lease = (struct lease *)0; Binary files DHCPD-BETA-5.16/dhcpd and DHCPD-BETA-5.17/dhcpd differ diff -rNc2 DHCPD-BETA-5.16/dhcpd.8 DHCPD-BETA-5.17/dhcpd.8 *** DHCPD-BETA-5.16/dhcpd.8 Thu Sep 5 16:53:17 1996 --- DHCPD-BETA-5.17/dhcpd.8 Tue Sep 16 16:09:22 1997 *************** *** 133,136 **** --- 133,144 ---- lightweight as a BOOTP database, dhcpd does not automatically restart itself when it sees a change to the dhcpd.conf file. + .PP + Note: We get a lot of complaints about this. We realize that it would + be nice if one could send a SIGHUP to the server and have it reload + the database. This is not technically impossible, but it would + require a great deal of work, our resources are extremely limited, and + they can be better spent elsewhere. So please don't complain about + this on the mailing list unless you're prepared to fund a project to + implement this feature, or prepared to do it yourself. .SH COMMAND LINE .PP diff -rNc2 DHCPD-BETA-5.16/dhcpd.c DHCPD-BETA-5.17/dhcpd.c *** DHCPD-BETA-5.16/dhcpd.c Sat Mar 29 00:11:03 1997 --- DHCPD-BETA-5.17/dhcpd.c Sat Mar 29 00:11:03 1997 *************** *** 49,53 **** "Copyright 1995, 1996 The Internet Software Consortium."; static char arr [] = "All rights reserved."; ! static char message [] = "Internet Software Consortium DHCPD $Name: BETA_5_16 $"; #include "dhcpd.h" --- 49,53 ---- "Copyright 1995, 1996 The Internet Software Consortium."; static char arr [] = "All rights reserved."; ! static char message [] = "Internet Software Consortium DHCPD $Name: BETA_5_17 $"; #include "dhcpd.h" diff -rNc2 DHCPD-BETA-5.16/dhcpd.cat8 DHCPD-BETA-5.17/dhcpd.cat8 *** DHCPD-BETA-5.16/dhcpd.cat8 Wed Dec 31 16:00:00 1969 --- DHCPD-BETA-5.17/dhcpd.cat8 Thu Sep 5 16:53:18 1996 *************** *** 0 **** --- 1,330 ---- + + + + dhcpd(8) dhcpd(8) + + + NNAAMMEE + dhcpd - Dynamic Host Configuration Protocol Server + + SSYYNNOOPPSSIISS + ddhhccppdd [ --pp _p_o_r_t ] [ --ff ] [ --dd ] [ --ccff _c_o_n_f_i_g_-_f_i_l_e ] [ --llff + _l_e_a_s_e_-_f_i_l_e ] [ _i_f_0 [ _._._._i_f_N ] ] + + DDEESSCCRRIIPPTTIIOONN + The Internet Software Consortium DHCP Server, dhcpd, + implements the Dynamic Host Configuration Protocol (DHCP) + and the Internet Bootstrap Protocol (BOOTP). DHCP allows + hosts on a TCP/IP network to request and be assigned IP + addresses, and also to discover information about the net- + work to which they are attached. BOOTP provides similar + functionality, with certain restrictions. + + OOPPEERRAATTIIOONN + The DHCP protocol allows a host which is unknown to the + network administrator to be automatically assigned a new + IP address out of a pool of IP addresses for its network. + In order for this to work, the network administrator allo- + cates address pools in each subnet and enters them into + the dhcpd.conf(5) file. + + On startup, dhcpd reads the _d_h_c_p_d_._c_o_n_f file and stores a + list of available addresses on each subnet in memory. + When a client requests an address using the DHCP protocol, + dhcpd allocates an address for it. Each client is + assigned a lease, which expires after an amount of time + chosen by the administrator (by default, one day). Before + leases expire, the clients to which leases are assigned + are expected to renew them in order to continue to use the + addresses. Once a lease has expired, the client to which + that lease was assigned is no longer permitted to use the + leased IP address. + + In order to keep track of leases across system reboots and + server restarts, dhcpd keeps a list of leases it has + assigned in the dhcpd.leases(5) file. Before dhcpd + grants a lease to a host, it records the lease in this + file and makes sure that the contents of the file are + flushed to disk. This ensures that even in the event of + a system crash, dhcpd will not forget about a lease that + it has assigned. On startup, after reading the + dhcpd.conf file, dhcpd reads the dhcpd.leases file to + refresh its memory about what leases have been assigned. + + New leases are appended to the end of the dhcpd.leases + file. In order to prevent the file from becoming arbi- + trarily large, from time to time dhcpd creates a new + dhcpd.leases file from its in-core lease database. Once + this file has been written to disk, the old file is + renamed _d_h_c_p_d_._l_e_a_s_e_s_~, and the new file is renamed + dhcpd.leases. If the system crashes in the middle of + + + + 1 + + + + + + dhcpd(8) dhcpd(8) + + + this process, whichever dhcpd.leases file remains will + contain all the lease information, so there is no need for + a special crash recovery process. + + BOOTP support is also provided by this server. Unlike + DHCP, the BOOTP protocol does not provide a protocol for + recovering dynamically-assigned addresses once they are no + longer needed. It is still possible to dynamically + assign addresses to BOOTP clients, but some administrative + process for reclaiming addresses is required. By + default, leases are granted to BOOTP clients in perpetu- + ity, although the network administrator may set an earlier + cutoff date or a shorter lease length for BOOTP leases if + that makes sense. + + BOOTP clients may also be served in the old standard way, + which is to simply provide a declaration in the dhcpd.conf + file for each BOOTP client, permanently assigning an + address to each client. + + Whenever changes are made to the dhcpd.conf file, dhcpd + must be restarted. To restart dhcpd, send a SIGTERM + (signal 15) to the process ID contained in + _/_v_a_r_/_r_u_n_/_d_h_c_p_d_._p_i_d, and then re-invoke dhcpd. Because the + DHCP server database is not as lightweight as a BOOTP + database, dhcpd does not automatically restart itself when + it sees a change to the dhcpd.conf file. + + CCOOMMMMAANNDD LLIINNEE + The names of the network interfaces on which dhcpd should + listen for broadcasts may be specified on the command + line. This should be done on systems where dhcpd is + unable to identify non-broadcast interfaces, but should + not be required on other systems. If no interface names + are specified on the command line dhcpd will identify all + network interfaces which are up, elimininating non- + broadcast interfaces if possible, and listen for DHCP + broadcasts on each interface. + + If dhcpd should listen on a port other than the standard + (port 67), the --pp flag may used. It should be followed by + the udp port number on which dhcpd should listen. This is + mostly useful for debugging purposes. + + To run dhcpd as a foreground process, rather than allowing + it to run as a daemon in the background, the --ff flag + should be specified. This is useful when running dhcpd + under a debugger, or when running it out of inittab on + System V systems. + + To have dhcpd log to the standard error descriptor, spec- + ify the --dd flag. This can be useful for debugging, and + also at sites where a complete log of all dhcp activity + must be kept but syslogd is not reliable or otherwise + + + + 2 + + + + + + dhcpd(8) dhcpd(8) + + + cannot be used. Normally, dhcpd will log all output + using the syslog(3) function with the log facility set to + LOG_DAEMON. + + Dhcpd can be made to use an alternate configuration file + with the --ccff flag, or an alternate lease file with the --llff + flag. Because of the importance of using the same lease + database at all times when running dhcpd in production, + these options should be used oonnllyy for testing lease files + or database files in a non-production environment. + + CCOONNFFIIGGUURRAATTIIOONN + The syntax of the dhcpd.conf(8) file is discussed seper- + ately. This section should be used as an overview of the + configuration process, and the dhcpd.conf(8) documentation + should be consulted for detailed reference information. + + + SSuubbnneettss + dhcpd needs to know the subnet numbers and netmasks of all + subnets for which it will be providing service. In addi- + tion, in order to dynamically allocate addresses, it must + be assigned one or more ranges of addresses on each subnet + which it can in turn assign to client hosts as they boot. + Thus, a very simple configuration providing DHCP support + might look like this: + + subnet 239.252.197.0 netmask 255.255.255.0 { + range 239.252.197.10 239.252.197.250; + } + + Multiple address ranges may be specified like this: + + subnet 239.252.197.0 netmask 255.255.255.0 { + range 239.252.197.10 239.252.197.107; + range 239.252.197.113 239.252.197.250; + } + + If a subnet will only be provided with BOOTP service and + no dynamic address assignment, the range clause can be + left out entirely, but the subnet statement must appear. + + + LLeeaassee LLeennggtthhss + DHCP leases can be assigned almost any length from zero + seconds to infinity. What lease length makes sense for + any given subnet, or for any given installation, will vary + depending on the kinds of hosts being served. + + For example, in an office environment where systems are + added from time to time and removed from time to time, but + move relatively infrequently, it might make sense to allow + lease times of a month of more. In a final test environ- + ment on a manufacturing floor, it may make more sense to + + + + 3 + + + + + + dhcpd(8) dhcpd(8) + + + assign a maximum lease length of 30 minutes - enough time + to go through a simple test procedure on a network appli- + ance before packaging it up for delivery. + + It is possible to specify two lease lengths: the default + length that will be assigned if a client doesn't ask for + any particular lease length, and a maximum lease length. + These are specified as clauses to the subnet command: + + subnet 239.252.197.0 netmask 255.255.255.0 { + range 239.252.197.10 239.252.197.107; + default-lease-time 600; + max-lease-time 7200; + | + + This particular subnet declaration specifies a default + lease time of 600 seconds (ten minutes), and a maximum + lease time of 7200 seconds (two hours). Other common + values would be 86400 (one day), 604800 (one week) and + 2592000 (30 days). + + Each subnet need not have the same lease--in the case of + an office environment and a manufacturing environment + served by the same DHCP server, it might make sense to + have widely disparate values for default and maximum lease + times on each subnet. + + BBOOOOTTPP SSuuppppoorrtt + Each BOOTP client must be explicitly declared in the + dhcpd.conf file. A very basic client declaration will + specify the client network interface's hardware address + and the IP address to assign to that client. If the + client needs to be able to load a boot file from the + server, that file's name must be specified. A simple + bootp client declaration might look like this: + + host haagen { + hardware ethernet 08:00:2b:4c:59:23; + fixed-address 239.252.197.9; + filename "/tftpboot/haagen.boot"; + } + + OOppttiioonnss + DHCP (and also BOOTP with Vendor Extensions) provide a + mechanism whereby the server can provide the client with + information about how to configure its network interface + (e.g., subnet mask), and also how the client can access + various network services (e.g., DNS, IP routers, and so + on). + + These options can be specified on a per-subnet basis, and, + for BOOTP clients, also on a per-client basis. In the + event that a BOOTP client declaration specifies options + that are also specified in its subnet declaration, the + + + + 4 + + + + + + dhcpd(8) dhcpd(8) + + + options specified in the client declaration take prece- + dence. An reasonably complete DHCP configuration might + look something like this: + + subnet 239.252.197.0 netmask 255.255.255.0 { + range 239.252.197.10 239.252.197.250; + default-lease-time 600 max-lease-time 7200; + option subnet-mask 255.255.255.0; + option broadcast-address 239.252.197.255; + option routers 239.252.197.1; + option domain-name-servers 239.252.197.2, 239.252.197.3; + option domain-name "isc.org"; + } + + A bootp host on that subnet that needs to be in a differ- + ent domain and use a different name server might be + declared as follows: + + host haagen hardware ethernet 08:00:2b:4c:59:23 { + fixed-address 239.252.197.9; + filename "/tftpboot/haagen.boot"; + option domain-name-servers 192.5.5.1; + option domain-name "vix.com"; + } + + A more complete description of the dhcpd.conf file syntax + is provided in dhcpd.conf(5). + + FFIILLEESS + //eettcc//ddhhccppdd..ccoonnff,, //vvaarr//ddbb//ddhhccppdd..lleeaasseess,, //vvaarr//rruunn//ddhhccppdd..ppiidd,, + //vvaarr//ddbb//ddhhccppdd..lleeaasseess~~.. + + SSEEEE AALLSSOO + dhcpd.conf(5), dhcpd.leases(5) + + AAUUTTHHOORR + ddhhccppdd((88)) was written by Ted Lemon under a + contract with Vixie Labs. Funding for this project was + provided by the Internet Software Corporation. Informa- + tion about the Internet Software Consortium can be found + at hhttttpp::////wwwwww..iisscc..oorrgg//iisscc.. + + + + + + + + + + + + + + + + + 5 + + diff -rNc2 DHCPD-BETA-5.16/dhcpd.conf.5 DHCPD-BETA-5.17/dhcpd.conf.5 *** DHCPD-BETA-5.16/dhcpd.conf.5 Fri May 9 01:37:51 1997 --- DHCPD-BETA-5.17/dhcpd.conf.5 Sat Nov 29 00:03:48 1997 *************** *** 66,71 **** on those parameters may be specified. .PP ! Declarations about network topology include the ! \fIserver-identifier\fR, the \fIshared-network\fR and the \fIsubnet\fR declarations. If clients on a subnet are to be assigned addresses dynamically, a \fIrange\fR declaration must appear within the --- 66,71 ---- on those parameters may be specified. .PP ! Declarations about network topology include the \fIshared-network\fR ! and the \fIsubnet\fR declarations. If clients on a subnet are to be assigned addresses dynamically, a \fIrange\fR declaration must appear within the *************** *** 77,84 **** can be used. .PP ! Each dhcpd.conf file must have one (and only one) ! .I server-identifier ! declaration, which tells dhcpd the identifier to use when issuing ! leases. For every subnet which will be served, and for every subnet to which the dhcp server is connected, there must be one \fIsubnet\fR declaration, which tells dhcpd how to recognize that an address is on --- 77,81 ---- can be used. .PP ! For every subnet which will be served, and for every subnet to which the dhcp server is connected, there must be one \fIsubnet\fR declaration, which tells dhcpd how to recognize that an address is on *************** *** 127,131 **** .nf - server-identifier dhcps.isc.org; .I global parameters... --- 124,127 ---- *************** *** 165,169 **** .fi .PP ! Notice that after the server-identifier declaration, there's a place for global parameters. These might be things like the organization's domain name, the addresses of the name servers (if they are common to --- 161,165 ---- .fi .PP ! Notice that at the beginning of the file, there's a place for global parameters. These might be things like the organization's domain name, the addresses of the name servers (if they are common to *************** *** 283,300 **** .SH REFERENCE: DECLARATIONS .PP - .B The - .I server-identifier - .B statement - .PP - \fBserver-identifier \fIhostname\fR\fB;\fR - .PP - The server-identifier declaration must be used exactly once in each - dhcpd.conf file to tell dhcpd what IP address to use as its server - identifier, as required by the DHCP protocol. On a machine with a - single interface, the server identifier should be the primary address - of that interface. On machines with multiple interfaces, the address - of one such interface must be chosen. Any address may be chosen, as - long as it is the address of one of the interfaces of that machine. - .PP .B The .I shared-network --- 279,282 ---- *************** *** 444,447 **** --- 426,438 ---- a group of declarations. It can be used to group hosts, shared networks, subnets, or even other groups. + .PP + .B The + .I server-identifier + .B statement + .PP + \fBserver-identifier \fIhostname\fR\fB;\fR + .PP + The server-identifier declaration is obsolete and is ignored by the + DHCP Server. .SH REFERENCE: PARAMETERS .PP *************** *** 525,530 **** \fIfilename\fR statement) is to be loaded. \fIServer-name\fR should be a numeric IP address or a domain name. If no \fInext-server\fR ! parameter applies to a given client, the address specified in the ! \fIserver-identifier\fR statement is used. .PP .B The --- 516,521 ---- \fIfilename\fR statement) is to be loaded. \fIServer-name\fR should be a numeric IP address or a domain name. If no \fInext-server\fR ! parameter applies to a given client, the DHCP server's IP address is ! used. .PP .B The diff -rNc2 DHCPD-BETA-5.16/dhcpd.conf.cat5 DHCPD-BETA-5.17/dhcpd.conf.cat5 *** DHCPD-BETA-5.16/dhcpd.conf.cat5 Wed Dec 31 16:00:00 1969 --- DHCPD-BETA-5.17/dhcpd.conf.cat5 Thu Sep 12 15:24:15 1996 *************** *** 0 **** --- 1,1188 ---- + + + + dhcpd.conf(5) dhcpd.conf(5) + + + NNAAMMEE + dhcpd.conf - dhcpd configuration file + + DDEESSCCRRIIPPTTIIOONN + The dhcpd.conf file contains configuration information for + _d_h_c_p_d_, the Internet Software Consortium DHCP Server. + + The dhcpd.conf file is a free-form ASCII text file. It + is parsed by the recursive-descent parser built into + dhcpd. The file may contain extra tabs and newlines for + formatting purposes. Keywords in the file are case- + insensitive. Comments may be placed anywhere within the + file (except within quotes). Comments begin with the # + character and end at the end of the line. + + The file essentially consists of a list of statements. + Statements fall into two broad categories - parameters and + declarations. + + Parameter statements either say how to do something (e.g., + how long a lease to offer), whether to do something (e.g., + should dhcpd provide addresses to unknown clients), or + what parameters to provide to the client (e.g., use gate- + way 220.177.244.7). + + Declarations are used to describe the topology of the net- + work, to describe clients on the network, to provide + addresses that can be assigned to clients, or to apply a + group of parameters to a group of declarations. In any + group of parameters and declarations, all parameters must + be specified before any declarations which depend on those + parameters may be specified. + + Declarations about network topology include the _s_e_r_v_e_r_- + _i_d_e_n_t_i_f_i_e_r, the _s_h_a_r_e_d_-_n_e_t_w_o_r_k and the _s_u_b_n_e_t declara- + tions. If clients on a subnet are to be assigned + addresses dynamically, a _r_a_n_g_e declaration must appear + within the _s_u_b_n_e_t declaration. For clients with stati- + cally assigned addresses, or for installations where only + known clients will be served, each such client must have a + _h_o_s_t declaration. If parameters are to be applied to a + group of declarations which are not related strictly on a + per-subnet basis, the _g_r_o_u_p declaration can be used. + + Each dhcpd.conf file must have one (and only one) _s_e_r_v_e_r_- + _i_d_e_n_t_i_f_i_e_r declaration, which tells dhcpd the identifier + to use when issuing leases. For every subnet which will + be served, and for every subnet to which the dhcp server + is connected, there must be one _s_u_b_n_e_t declaration, which + tells dhcpd how to recognize that an address is on that + subnet. A _s_u_b_n_e_t declaration is required for each subnet + even if no addresses will be dynamically allocated on that + subnet. + + + + + 1 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + Some installations have physical networks on which more + than one IP subnet operates. For example, if there is a + site-wide requirement that 8-bit subnet masks be used, but + a department with a single physical ethernet network + expands to the point where it has more than 254 nodes, it + may be necessary to run two 8-bit subnets on the same eth- + ernet until such time as a new physical network can be + added. In this case, the _s_u_b_n_e_t declarations for these + two networks may be enclosed in a _s_h_a_r_e_d_-_n_e_t_w_o_r_k declara- + tion. + + Some sites may have departments which have clients on more + than one subnet, but it may be desirable to offer those + clients a uniform set of parameters which are different + than what would be offered to clients from other depart- + ments on the same subnet. For clients which will be + declared explicitly with _h_o_s_t declarations, these declara- + tions can be enclosed in a _g_r_o_u_p declaration along with + the parameters which are common to that department. For + clients whose addresses will be dynamically assigned, + there is currently no way to group parameter assignments + other than by network topology. + + When a client is to be booted, its boot parameters are + determined by first consulting that client's _h_o_s_t declara- + tion (if any), then consulting the _g_r_o_u_p declaration (if + any) which enclosed that _h_o_s_t declaration, then consulting + the _s_u_b_n_e_t declaration for the subnet on which the client + is booting, then consulting the _s_h_a_r_e_d_-_n_e_t_w_o_r_k declaration + (if any) containing that subnet, and finally consulting + the top-level parameters which may be specified outside of + any declaration. + + When dhcpd tries to find a _h_o_s_t declaration for a client, + it first looks for a _h_o_s_t declaration which has a _f_i_x_e_d_- + _a_d_d_r_e_s_s parameter which matches the subnet or shared net- + work on which the client is booting. If it doesn't find + any such entry, it then tries to find an entry which has + no _f_i_x_e_d_-_a_d_d_r_e_s_s parameter. If no such entry is found, + then dhcpd acts as if there is no entry in the dhcpd.conf + file for that client, even if there is an entry for that + client on a different subnet or shared network. + + EEXXAAMMPPLLEESS + A typical dhcpd.conf file will look something like this: + + server-identifier dhcps.isc.org; + _g_l_o_b_a_l _p_a_r_a_m_e_t_e_r_s_._._. + + shared-network ISC-BIGGIE { + _s_h_a_r_e_d_-_n_e_t_w_o_r_k_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + subnet 204.254.239.0 netmask 255.255.255.224 { + _s_u_b_n_e_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + range 204.254.239.10 204.254.239.30; + + + + 2 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + } + subnet 204.254.239.32 netmask 255.255.255.224 { + _s_u_b_n_e_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + range 204.254.239.42 204.254.239.62; + } + } + + subnet 204.254.239.64 netmask 255.255.255.224 { + _s_u_b_n_e_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + range 204.254.239.74 204.254.239.94; + } + + group { + _g_r_o_u_p_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + host zappo.test.isc.org { + _h_o_s_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + } + host beppo.test.isc.org { + _h_o_s_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + } + host harpo.test.isc.org { + _h_o_s_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s_._._. + } + } + + Figure 1 + + + Notice that after the server-identifier declaration, + there's a place for global parameters. These might be + things like the organization's domain name, the addresses + of the name servers (if they are common to the entire + organization), and so on. So, for example: + + option domain-name "isc.org"; + option name-servers ns1.isc.org, ns2.isc.org; + + Figure 2 + + As you can see in Figure 2, it's legal to specify host + addresses in parameters as domain names rather than as + numeric IP addresses. If a given hostname resolves to + more than one IP address (for example, if that host has + two ethernet interfaces), both addresses are supplied to + the client. + + In Figure 1, you can see that both the shared-network + statement and the subnet statements can have parameters. + Let us say that the shared network _I_S_C_-_B_I_G_G_I_E supports an + entire department - perhaps the accounting department. + If accounting has its own domain, then a shared-network- + specific parameter might be: + + option domain-name "accounting.isc.org"; + + + + 3 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + All subnet declarations appearing in the shared-network + declaration would then have the domain-name option set to + "accounting.isc.org" instead of just "isc.org". + + The most obvious reason for having subnet-specific parame- + ters as shown in Figure 1 is that each subnet, of neces- + sity, has its own router. So for the first subnet, for + example, there should be something like: + + option routers 204.254.239.1; + + Note that the address here is specified numerically. + This is not required - if you have a different domain name + for each interface on your router, it's perfectly legiti- + mate to use the domain name for that interface instead of + the numeric address. However, in many cases there may be + only one domain name for all of a router's IP addresses, + and it would not be appropriate to use that name here. + + In Figure 1 there is also a _g_r_o_u_p statement, which pro- + vides common parameters for a set of three hosts - zappo, + beppo and harpo. As you can see, these hosts are all in + the test.isc.org domain, so it might make sense for a + group-specific parameter to override the domain name sup- + plied to these hosts: + + option domain-name "test.isc.org"; + + Also, given the domain they're in, these are probably test + machines. If we wanted to test the DHCP leasing mecha- + nism, we might set the lease timeout somewhat shorter than + the default: + + max-lease-time 120; + default-lease-time 120; + + You may have noticed that while some parameters start with + the _o_p_t_i_o_n keyword, some do not. Parameters starting + with the _o_p_t_i_o_n keyword correspond to actual DHCP options, + while parameters that do not start with the option keyword + either control the behaviour of the DHCP server (e.g., how + long a lease dhcpd will give out), or specify client + parameters that are not optional in the DHCP protocol (for + example, server-name and filename). + + In Figure 1, each host had _h_o_s_t_-_s_p_e_c_i_f_i_c _p_a_r_a_m_e_t_e_r_s. + These could include such things as the _h_o_s_t_n_a_m_e option, + the name of a file to upload (the _f_i_l_e_n_a_m_e _p_a_r_a_m_e_t_e_r_) _a_n_d + _t_h_e _a_d_d_r_e_s_s _o_f _t_h_e _s_e_r_v_e_r _f_r_o_m _w_h_i_c_h _t_o _u_p_l_o_a_d _t_h_e _f_i_l_e + _(_t_h_e _n_e_x_t_-_s_e_r_v_e_r parameter). In general, any parameter + can appear anywhere that parameters are allowed, and will + be applied according to the scope in which the parameter + appears. + + + + + 4 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + Imagine that you have a site with a lot of NCD X- + Terminals. These terminals come in a variety of models, + and you want to specify the boot files for each models. + One way to do this would be to have host declarations for + each server and group them by model: + + group { + filename "Xncd19r"; + next-server ncd-booter; + + host ncd1 { hardware ethernet 0:c0:c3:49:2b:57; } + host ncd4 { hardware ethernet 0:c0:c3:80:fc:32; } + host ncd8 { hardware ethernet 0:c0:c3:22:46:81; } + } + + group { + filename "Xncd19c"; + next-server ncd-booter; + + host ncd2 { hardware ethernet 0:c0:c3:88:2d:81; } + host ncd3 { hardware ethernet 0:c0:c3:00:14:11; } + } + + group { + filename "XncdHMX"; + next-server ncd-booter; + + host ncd1 { hardware ethernet 0:c0:c3:11:90:23; } + host ncd4 { hardware ethernet 0:c0:c3:91:a7:8; } + host ncd8 { hardware ethernet 0:c0:c3:cc:a:8f; } + } + + RREEFFEERREENNCCEE:: DDEECCLLAARRAATTIIOONNSS + TThhee _s_e_r_v_e_r_-_i_d_e_n_t_i_f_i_e_r ssttaatteemmeenntt + + sseerrvveerr--iiddeennttiiffiieerr _h_o_s_t_n_a_m_e;; + + The server-identifier declaration must be used exactly + once in each dhcpd.conf file to tell dhcpd what IP address + to use as its server identifier, as required by the DHCP + protocol. On a machine with a single interface, the + server identifier should be the primary address of that + interface. On machines with multiple interfaces, the + address of one such interface must be chosen. Any + address may be chosen, as long as it is the address of one + of the interfaces of that machine. + + TThhee _s_h_a_r_e_d_-_n_e_t_w_o_r_k ssttaatteemmeenntt + + sshhaarreedd--nneettwwoorrkk _n_a_m_e {{ + [ _p_a_r_a_m_e_t_e_r_s ] + [ _d_e_c_l_a_r_a_t_i_o_n_s ] + }} + + + + + 5 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + The _s_h_a_r_e_d_-_n_e_t_w_o_r_k statement is used to inform the DHCP + server that some IP subnets actually share the same physi- + cal network. Any subnets in a shared network should be + declared within a _s_h_a_r_e_d_-_n_e_t_w_o_r_k statement. Parameters + specified in the _s_h_a_r_e_d_-_n_e_t_w_o_r_k statement will be used + when booting clients on those subnets unless parameters + provided at the subnet or host level override them. If + any subnet in a shared network has addresses available for + dynamic allocation, those addresses are collected into a + common pool for that shared network and assigned to + clients as needed. There is no way to distinguish on + which subnet of a shared network a client should boot. + + _N_a_m_e should be the name of the shared network. This name + is used when printing debugging messages, so it should be + descriptive for the shared network. The name may have + the syntax of a valid domain name (although it will never + be used as such), or it may be any arbitrary name, + enclosed in quotes. + + TThhee _s_u_b_n_e_t ssttaatteemmeenntt + + ssuubbnneett _s_u_b_n_e_t_-_n_u_m_b_e_r nneettmmaasskk _n_e_t_m_a_s_k {{ + [ _p_a_r_a_m_e_t_e_r_s ] + [ _d_e_c_l_a_r_a_t_i_o_n_s ] + }} + + The _s_u_b_n_e_t statement is used to provide dhcpd with enough + information to tell whether or not an IP address is on + that subnet. It may also be used to provide subnet- + specific parameters and to specify what addresses may be + dynamically allocated to clients booting on that subnet. + Such addresses are specified using the _r_a_n_g_e declaration. + + The _s_u_b_n_e_t_-_n_u_m_b_e_r should be an IP address or domain name + which resolves to the subnet number of the subnet being + described. The _n_e_t_m_a_s_k should be an IP address or domain + name which resolves to the subnet mask of the subnet being + described. The subnet number, together with the netmask, + are sufficient to determine whether any given IP address + is on the specified subnet. + + Although a netmask must be given with every subnet decla- + ration, it is recommended that if there is any variance in + subnet masks at a site, a subnet-mask option statement be + used in each subnet declaration to set the desired subnet + mask, since any subnet-mask option statement will override + the subnet mask declared in the subnet statement. + + TThhee _r_a_n_g_e ssttaatteemmeenntt + + rraannggee [ ddyynnaammiicc--bboooottpp ] _l_o_w_-_a_d_d_r_e_s_s [ _h_i_g_h_-_a_d_d_r_e_s_s];; + + For any subnet on which addresses will be assigned + + + + 6 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + dynamically, there must be at least one _r_a_n_g_e statement. + The range statement gives the lowest and highest IP + addresses in a range. All IP addresses in the range + should be in the subnet in which the _r_a_n_g_e statement is + declared. The _d_y_n_a_m_i_c_-_b_o_o_t_p flag may be specified if + addresses in the specified range may be dynamically + assigned to BOOTP clients as well as DHCP clients. When + specifying a single address, _h_i_g_h_-_a_d_d_r_e_s_s can be omitted. + + TThhee _h_o_s_t ssttaatteemmeenntt + + hhoosstt _h_o_s_t_n_a_m_e { + [ _p_a_r_a_m_e_t_e_r_s ] + [ _d_e_c_l_a_r_a_t_i_o_n_s ] + }} + + There must be at least one hhoosstt statement for every BOOTP + client that is to be served. hhoosstt statements may also be + specified for DHCP clients, although this is not required + unless booting is only enabled for known hosts. + + If it is desirable to be able to boot a DHCP or BOOTP + client on more than one subnet with fixed addresses, more + than one address may be specified in the _f_i_x_e_d_-_a_d_d_r_e_s_s + parameter, or more than one hhoosstt statement may be speci- + fied. + + If client-specific boot parameters must change based on + the network to which the client is attached, then multiple + hhoosstt statements should be used. + + If a client is to be booted using a fixed address if it's + possible, but should be allocated a dynamic address other- + wise, then a hhoosstt statement must be specified without a + ffiixxeedd--aaddddrreessss clause. _h_o_s_t_n_a_m_e should be a name identify- + ing the host. If a _h_o_s_t_n_a_m_e option is not specified for + the host, _h_o_s_t_n_a_m_e is used. + + _H_o_s_t declarations are matched to actual DHCP or BOOTP + clients by matching the dhcp-client-identifier option + specified in the _h_o_s_t declaration to the one supplied by + the client, or, if the _h_o_s_t declaration or the client does + not provide a dhcp-client-identifier option, by matching + the _h_a_r_d_w_a_r_e parameter in the _h_o_s_t declaration to the net- + work hardware address supplied by the client. BOOTP + clients do not normally provide a _d_h_c_p_-_c_l_i_e_n_t_-_i_d_e_n_t_i_f_i_e_r, + so the hardware address must be used for all clients that + may boot using the BOOTP protocol. + + TThhee _g_r_o_u_p ssttaatteemmeenntt + + ggrroouupp { + [ _p_a_r_a_m_e_t_e_r_s ] + [ _d_e_c_l_a_r_a_t_i_o_n_s ] + + + + 7 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + }} + + The group statement is used simply to apply one or more + parameters to a group of declarations. It can be used to + group hosts, shared networks, subnets, or even other + groups. + + RREEFFEERREENNCCEE:: PPAARRAAMMEETTEERRSS + TThhee _d_e_f_a_u_l_t_-_l_e_a_s_e_-_t_i_m_e ssttaatteemmeenntt + + ddeeffaauulltt--lleeaassee--ttiimmee _t_i_m_e;; + + _T_i_m_e should be the length in seconds that will be assigned + to a lease if the client requesting the lease does not ask + for a specific expiration time. + + TThhee _m_a_x_-_l_e_a_s_e_-_t_i_m_e ssttaatteemmeenntt + + mmaaxx--lleeaassee--ttiimmee _t_i_m_e;; + + _T_i_m_e should be the maximum length in seconds that will be + assigned to a lease if the client requesting the lease + asks for a specific expiration time. + + TThhee _h_a_r_d_w_a_r_e ssttaatteemmeenntt + + hhaarrddwwaarree _h_a_r_d_w_a_r_e_-_t_y_p_e _h_a_r_d_w_a_r_e_-_a_d_d_r_e_s_s;; + + In order for a BOOTP client to be recognized, its network + hardware address must be declared using a _h_a_r_d_w_a_r_e clause + in the _h_o_s_t statement. _h_a_r_d_w_a_r_e_-_t_y_p_e must be the name of + a physical hardware interface type. Currently, only the + eetthheerrnneett type is recognized, although support for ttookkeenn-- + rriinngg and ffddddii hardware types would also be desirable. The + _h_a_r_d_w_a_r_e_-_a_d_d_r_e_s_s should be a set of hexadecimal octets + (numbers from 0 through ff) seperated by colons. The + _h_a_r_d_w_a_r_e_f_R _s_t_a_t_e_m_e_n_t _m_a_y _a_l_s_o _b_e _u_s_e_d _f_o_r _D_H_C_P _c_l_i_e_n_t_s_. + + TThhee _f_i_l_e_n_a_m_e ssttaatteemmeenntt + + ffiilleennaammee ""_f_i_l_e_n_a_m_e"";; + + The _f_i_l_e_n_a_m_e statement can be used to specify the name of + the initial boot file which is to be loaded by a client. + The _f_i_l_e_n_a_m_e should be a filename recognizable to whatever + file transfer protocol the client can be expected to use + to load the file. + + TThhee _s_e_r_v_e_r_-_n_a_m_e ssttaatteemmeenntt + + sseerrvveerr--nnaammee ""_n_a_m_e"";; + + The _s_e_r_v_e_r_-_n_a_m_e statement can be used to inform the client + of the name of the server from which it is booting. _N_a_m_e + + + + 8 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + should be the name that will be provided to the client. + + TThhee _n_e_x_t_-_s_e_r_v_e_r ssttaatteemmeenntt + + nneexxtt--sseerrvveerr _s_e_r_v_e_r_-_n_a_m_e;; + + The _n_e_x_t_-_s_e_r_v_e_r statement is used to specify the host + address of the server from which the initial boot file + (specified in the _f_i_l_e_n_a_m_e statement) is to be loaded. + _S_e_r_v_e_r_-_n_a_m_e should be a numeric IP address or a domain + name. If no _n_e_x_t_-_s_e_r_v_e_r parameter applies to a given + client, the address specified in the _s_e_r_v_e_r_-_i_d_e_n_t_i_f_i_e_r + statement is used. + + TThhee _f_i_x_e_d_-_a_d_d_r_e_s_s ssttaatteemmeenntt + + ffiixxeedd--aaddddrreessss _a_d_d_r_e_s_s [,, _a_d_d_r_e_s_s ... ];; + + The _f_i_x_e_d_-_a_d_d_r_e_s_s statement is used to assign one or more + fixed IP addresses to a client. It should only appear in + a _h_o_s_t declaration. If more than one address is supplied, + then when the client boots, it will be assigned the + address which corresponds to the network on which it is + booting. If none of the addresses in the _f_i_x_e_d_-_a_d_d_r_e_s_s + statement are on the network on which the client is boot- + ing, that client will not match the _h_o_s_t declaration con- + taining that _f_i_x_e_d_-_a_d_d_r_e_s_s statement. Each _a_d_d_r_e_s_s should + be either an IP address or a domain name which resolves to + one or more IP addresses. + + TThhee _d_y_n_a_m_i_c_-_b_o_o_t_p_-_l_e_a_s_e_-_c_u_t_o_f_f ssttaatteemmeenntt + + ddyynnaammiicc--bboooottpp--lleeaassee--ccuuttooffff _d_a_t_e;; + + The _d_y_n_a_m_i_c_-_b_o_o_t_p_-_l_e_a_s_e_-_c_u_t_o_f_f statement sets the ending + time for all leases assigned dynamically to BOOTP clients. + Because BOOTP clients do not have any way of renewing + leases, and don't know that their leases could expire, by + default dhcpd assignes infinite leases to all BOOTP + clients. However, it may make sense in some situations to + set a cutoff date for all BOOTP leases - for example, the + end of a school term, or the time at night when a facility + is closed and all machines are required to be powered off. + + _D_a_t_e should be the date on which all assigned BOOTP leases + will end. The date is specified in the form: + + W YYYY/MM/DD HH:MM:SS + + W is the day of the week expressed as a number from zero + (Sunday) to six (Saturday). YYYY is the year, including + the century. MM is the month expressed as a number from 1 + to 12. DD is the day of the month, counting from 1. HH + is the hour, from zero to 23. MM is the minute and SS is + + + + 9 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + the second. The time is always in Greenwich Mean Time + (GMT), not local time. + + TThhee _d_y_n_a_m_i_c_-_b_o_o_t_p_-_l_e_a_s_e_-_l_e_n_g_t_h ssttaatteemmeenntt + + ddyynnaammiicc--bboooottpp--lleeaassee--lleennggtthh _l_e_n_g_t_h;; + + The _d_y_n_a_m_i_c_-_b_o_o_t_p_-_l_e_a_s_e_-_l_e_n_g_t_h statement is used to set + the length of leases dynamically assigned to BOOTP + clients. At some sites, it may be possible to assume + that a lease is no longer in use if its holder has not + used BOOTP or DHCP to get its address within a certain + time period. The period is specified in _l_e_n_g_t_h as a num- + ber of seconds. If a client reboots using BOOTP during + the timeout period, the lease duration is reset to _l_e_n_g_t_h, + so a BOOTP client that boots frequently enough will never + lose its lease. Needless to say, this parameter should be + adjusted with extreme caution. + + TThhee _b_o_o_t_-_u_n_k_n_o_w_n_-_c_l_i_e_n_t_s ssttaatteemmeenntt + + bboooott--uunnkknnoowwnn--cclliieennttss _f_l_a_g;; + + The _b_o_o_t_-_u_n_k_n_o_w_n_-_c_l_i_e_n_t_s statement is used to tell dhcpd + whether or not to dynamically assign addresses to unknown + clients. If _f_l_a_g is true (the default), then addresses + are dynamically assigned to unknown clients when avail- + able. If _f_l_a_g is false, then addresses are provided only + to clients which match at least one host declaration. + + TThhee _g_e_t_-_l_e_a_s_e_-_h_o_s_t_n_a_m_e_s ssttaatteemmeenntt + + ggeett--lleeaassee--hhoossttnnaammeess _f_l_a_g;; + + The _g_e_t_-_l_e_a_s_e_-_h_o_s_t_n_a_m_e_s statement is used to tell dhcpd + whether or not to look up the domain name corresponding to + the IP address of each address in the lease pool and use + that address for the DHCP _h_o_s_t_n_a_m_e option. If _f_l_a_g is + true, then this lookup is done for all addresses in the + current scope. By default, or if _f_l_a_g is false, no + lookups are done. + + TThhee _u_s_e_-_h_o_s_t_-_d_e_c_l_-_n_a_m_e_s ssttaatteemmeenntt + + uussee--hhoosstt--ddeeccll--nnaammeess _f_l_a_g;; + + If the _u_s_e_-_h_o_s_t_-_d_e_c_l_-_n_a_m_e_s parameter is true in a given + scope, then for every host declaration within that scope, + the name provided for the host declaration will be sup- + plied to the client as its hostname. So, for example, + + group { + use-host-decl-names on; + + + + + 10 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + host joe { + hardware ethernet 08:00:2b:4c:29:32; + fixed-address joe.fugue.com; + } + } + + is equivalent to + + host joe { + hardware ethernet 08:00:2b:4c:29:32; + fixed-address joe.fugue.com; + option host-name "joe"; + } + + An _o_p_t_i_o_n _h_o_s_t_-_n_a_m_e statement within a host declaration + will override the use of the name in the host declaration. + + RREEFFEERREENNCCEE:: OOPPTTIIOONN SSTTAATTEEMMEENNTTSS + DHCP _o_p_t_i_o_n statements always start with the _o_p_t_i_o_n key- + word, followed by an option name, followed by option data. + The option names and data formats are described below. + It is not necessary to exhaustively specify all DHCP + options - only those options which are needed by clients + must be specified. + + Option data comes in a variety of formats, as defined + below: + + The iipp--aaddddrreessss data type can be entered either as an + explicit IP address (e.g., 239.254.197.10) or as a domain + name (e.g., haagen.isc.org). When entering a domain name, + be sure that that domain name resolves to a single IP + address. + + The iinntt3322 data type specifies a signed 32-bit integer. + The uuiinntt3322 data type specifies an unsigned 32-bit integer. + The iinntt1166 and uuiinntt1166 data types specify signed and + unsigned 16-bit integers. The iinntt88 and uuiinntt88 data types + specify signed and unsigned 8-bit integers. Unsigned + 8-bit integers are also sometimes referred to as octets. + + The ssttrriinngg data type specifies an NVT ASCII string, which + must be enclosed in double quotes - for example, to spec- + ify a domain-name option, the syntax would be + + option domain-name "isc.org"; + + The ffllaagg data type specifies a boolean value. Booleans + can be either true or false (or on or off, if that makes + more sense to you). + + The ddaattaa--ssttrriinngg data type specifies either an NVT ASCII + string enclosed in double quotes, or a series of octets + specified in hexadecimal, seperated by colons. For + + + + 11 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + example: + + option client-identifier "CLIENT-FOO"; + or + option client-identifier 43:4c:49:45:54:2d:46:4f:4f; + + The documentation for the various options mentioned below + is taken from the latest IETF draft document on DHCP + options. Options which are not listed by name may be + defined by the name option-_n_n_n, where _n_n_n _i_s _t_h_e _d_e_c_i_m_a_l + _n_u_m_b_e_r _o_f _t_h_e _o_p_t_i_o_n _c_o_d_e_. _T_h_e_s_e _o_p_t_i_o_n_s _m_a_y _b_e _f_o_l_l_o_w_e_d + _e_i_t_h_e_r _b_y _a _s_t_r_i_n_g_, _e_n_c_l_o_s_e_d _i_n _q_u_o_t_e_s_, _o_r _b_y _a _s_e_r_i_e_s _o_f + _o_c_t_e_t_s_, _e_x_p_r_e_s_s_e_d _a_s _t_w_o_-_d_i_g_i_t _h_e_x_a_d_e_c_i_m_a_l _n_u_m_b_e_r_s _s_e_p_e_r_- + _a_t_e_d _b_y _c_o_l_o_n_s_. _F_o_r _e_x_a_m_p_l_e_: + + option option-133 "my-option-133-text"; + option option-129 1:54:c9:2b:47; + + Because dhcpd does not know the format of these undefined + option codes, no checking is done to ensure the correct- + ness of the entered data. + + The standard options are: + + ooppttiioonn ssuubbnneett--mmaasskk _i_p_-_a_d_d_r_e_s_s;; + + The subnet mask option specifies the client's subnet mask + as per RFC 950. If no subnet mask option is provided any- + where in scope, as a last resort dhcpd will use the subnet + mask from the subnet declaration for the network on which + an address is being assigned. However, _a_n_y subnet-mask + option declaration that is in scope for the address being + assigned will override the subnet mask specified in the + subnet declaration. + + ooppttiioonn ttiimmee--ooffffsseett _i_n_t_3_2;; + + The time-offset option specifies the offset of the + client's subnet in seconds from Coordinated Universal Time + (UTC). + + ooppttiioonn rroouutteerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The routers option specifies a list of IP addresses for + routers on the client's subnet. Routers should be listed + in order of preference. + + ooppttiioonn ttiimmee--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s _[_, _i_p_-_a_d_d_r_e_s_s ... ];; + + The time-server option specifies a list of RFC 868 time + servers available to the client. Servers should be listed + in order of preference. + + ooppttiioonn nnaammee--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ]; + + + + 12 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + The name-servers option specifies a list of IEN 116 name + servers available to the client. Servers should be listed + in order of preference. + + ooppttiioonn ddoommaaiinn--nnaammee--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... + ];; + + The domain-name-servers option specifies a list of Domain + Name System (STD 13, RFC 1035) name servers available to + the client. Servers should be listed in order of prefer- + ence. + + ooppttiioonn lloogg--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The log-server option specifies a list of MIT-LCS UDP log + servers available to the client. Servers should be listed + in order of preference. + + ooppttiioonn ccooookkiiee--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The cookie server option specifies a list of RFC 865 + cookie servers available to the client. Servers should be + listed in order of preference. + + ooppttiioonn llpprr--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The LPR server option specifies a list of RFC 1179 line + printer servers available to the client. Servers should + be listed in order of preference. + + ooppttiioonn iimmpprreessss--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The impress-server option specifies a list of Imagen + Impress servers available to the client. Servers should + be listed in order of preference. + + ooppttiioonn rreessoouurrccee--llooccaattiioonn--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s + ... ];; + + This option specifies a list of RFC 887 Resource Location + servers available to the client. Servers should be listed + in order of preference. + + ooppttiioonn hhoosstt--nnaammee _s_t_r_i_n_g;; + + This option specifies the name of the client. The name + may or may not be qualified with the local domain name (it + is preferable to use the domain-name option to specify the + domain name). See RFC 1035 for character set restric- + tions. + + ooppttiioonn bboooott--ssiizzee _u_i_n_t_1_6;; + + This option specifies the length in 512-octet blocks of + + + + 13 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + the default boot image for the client. + + ooppttiioonn mmeerriitt--dduummpp _s_t_r_i_n_g;; + + This option specifies the path-name of a file to which the + client's core image should be dumped in the event the + client crashes. The path is formatted as a character + string consisting of characters from the NVT ASCII charac- + ter set. + + ooppttiioonn ddoommaaiinn--nnaammee _s_t_r_i_n_g;; + + This option specifies the domain name that client should + use when resolving hostnames via the Domain Name System. + + ooppttiioonn sswwaapp--sseerrvveerr _i_p_-_a_d_d_r_e_s_s;; + + This specifies the IP address of the client's swap server. + + ooppttiioonn rroooott--ppaatthh _s_t_r_i_n_g;; + + This option specifies the path-name that contains the + client's root disk. The path is formatted as a character + string consisting of characters from the NVT ASCII charac- + ter set. + + ooppttiioonn iipp--ffoorrwwaarrddiinngg _f_l_a_g;; + + This option specifies whether the client should configure + its IP layer for packet forwarding. A value of 0 means + disable IP forwarding, and a value of 1 means enable IP + forwarding. + + ooppttiioonn nnoonn--llooccaall--ssoouurrccee--rroouuttiinngg _f_l_a_g;; + + This option specifies whether the client should configure + its IP layer to allow forwarding of datagrams with non- + local source routes (see Section 3.3.5 of [4] for a dis- + cussion of this topic). A value of 0 means disallow for- + warding of such datagrams, and a value of 1 means allow + forwarding. + + ooppttiioonn ppoolliiccyy--ffiilltteerr _i_p_-_a_d_d_r_e_s_s _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s + _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies policy filters for non-local source + routing. The filters consist of a list of IP addresses + and masks which specify destination/mask pairs with which + to filter incoming source routes. + + Any source routed datagram whose next-hop address does not + match one of the filters should be discarded by the + client. + + + + + 14 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + See STD 3 (RFC1122) for further information. + + ooppttiioonn mmaaxx--ddggrraamm--rreeaasssseemmbbllyy _u_i_n_t_1_6;; + + This option specifies the maximum size datagram that the + client should be prepared to reassemble. The minimum + value legal value is 576. + + ooppttiioonn ddeeffaauulltt--iipp--ttttll _u_i_n_t_8_; + + This option specifies the default time-to-live that the + client should use on outgoing datagrams. + + ooppttiioonn ppaatthh--mmttuu--aaggiinngg--ttiimmeeoouutt _u_i_n_t_3_2;; + + This option specifies the timeout (in seconds) to use when + aging Path MTU values discovered by the mechanism defined + in RFC 1191. + + ooppttiioonn ppaatthh--mmttuu--ppllaatteeaauu--ttaabbllee _u_i_n_t_1_6 [,, _u_i_n_t_1_6 ... ];; + + This option specifies a table of MTU sizes to use when + performing Path MTU Discovery as defined in RFC 1191. The + table is formatted as a list of 16-bit unsigned integers, + ordered from smallest to largest. The minimum MTU value + cannot be smaller than 68. + + ooppttiioonn iinntteerrffaaccee--mmttuu _u_i_n_t_1_6;; + + This option specifies the MTU to use on this interface. + The minimum legal value for the MTU is 68. + + ooppttiioonn aallll--ssuubbnneettss--llooccaall _f_l_a_g;; + + This option specifies whether or not the client may assume + that all subnets of the IP network to which the client is + connected use the same MTU as the subnet of that network + to which the client is directly connected. A value of 1 + indicates that all subnets share the same MTU. A value of + 0 means that the client should assume that some subnets of + the directly connected network may have smaller MTUs. + + ooppttiioonn bbrrooaaddccaasstt--aaddddrreessss _i_p_-_a_d_d_r_e_s_s;; + + This option specifies the broadcast address in use on the + client's subnet. Legal values for broadcast addresses are + specified in section 3.2.1.3 of STD 3 (RFC1122). + + ooppttiioonn ppeerrffoorrmm--mmaasskk--ddiissccoovveerryy _f_l_a_g;; + + This option specifies whether or not the client should + perform subnet mask discovery using ICMP. A value of 0 + indicates that the client should not perform mask discov- + ery. A value of 1 means that the client should perform + + + + 15 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + mask discovery. + + ooppttiioonn mmaasskk--ssuupppplliieerr _f_l_a_g;; + + This option specifies whether or not the client should + respond to subnet mask requests using ICMP. A value of 0 + indicates that the client should not respond. A value of + 1 means that the client should respond. + + ooppttiioonn rroouutteerr--ddiissccoovveerryy _f_l_a_g;; + + This option specifies whether or not the client should + solicit routers using the Router Discovery mechanism + defined in RFC 1256. A value of 0 indicates that the + client should not perform router discovery. A value of 1 + means that the client should perform router discovery. + + ooppttiioonn rroouutteerr--ssoolliicciittaattiioonn--aaddddrreessss _i_p_-_a_d_d_r_e_s_s;; + + This option specifies the address to which the client + should transmit router solicitation requests. + + ooppttiioonn ssttaattiicc--rroouutteess _i_p_-_a_d_d_r_e_s_s _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s + _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies a list of static routes that the + client should install in its routing cache. If multiple + routes to the same destination are specified, they are + listed in descending order of priority. + + The routes consist of a list of IP address pairs. The + first address is the destination address, and the second + address is the router for the destination. + + The default route (0.0.0.0) is an illegal destination for + a static route. To specify the default route, use the + rroouutteerrss option. + + ooppttiioonn ttrraaiilleerr--eennccaappssuullaattiioonn _f_l_a_g;; + + This option specifies whether or not the client should + negotiate the use of trailers (RFC 893 [14]) when using + the ARP protocol. A value of 0 indicates that the client + should not attempt to use trailers. A value of 1 means + that the client should attempt to use trailers. + + ooppttiioonn aarrpp--ccaacchhee--ttiimmeeoouutt _u_i_n_t_3_2;; + + This option specifies the timeout in seconds for ARP cache + entries. + + ooppttiioonn iieeeeee880022--33--eennccaappssuullaattiioonn _f_l_a_g;; + + This option specifies whether or not the client should use + + + + 16 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + Ethernet Version 2 (RFC 894) or IEEE 802.3 (RFC 1042) + encapsulation if the interface is an Ethernet. A value of + 0 indicates that the client should use RFC 894 encapsula- + tion. A value of 1 means that the client should use RFC + 1042 encapsulation. + + ooppttiioonn ddeeffaauulltt--ttccpp--ttttll _u_i_n_t_8;; + + This option specifies the default TTL that the client + should use when sending TCP segments. The minimum value + is 1. + + ooppttiioonn ttccpp--kkeeeeppaalliivvee--iinntteerrvvaall _u_i_n_t_3_2;; + + This option specifies the interval (in seconds) that the + client TCP should wait before sending a keepalive message + on a TCP connection. The time is specified as a 32-bit + unsigned integer. A value of zero indicates that the + client should not generate keepalive messages on connec- + tions unless specifically requested by an application. + + ooppttiioonn ttccpp--kkeeeeppaalliivvee--ggaarrbbaaggee _f_l_a_g;; + + This option specifies the whether or not the client should + send TCP keepalive messages with a octet of garbage for + compatibility with older implementations. A value of 0 + indicates that a garbage octet should not be sent. A value + of 1 indicates that a garbage octet should be sent. + + ooppttiioonn nniiss--ddoommaaiinn _s_t_r_i_n_g;; + + This option specifies the name of the client's NIS (Sun + Network Information Services) domain. The domain is for- + matted as a character string consisting of characters from + the NVT ASCII character set. + + ooppttiioonn nniiss--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies a list of IP addresses indicating + NIS servers available to the client. Servers should be + listed in order of preference. + + ooppttiioonn nnttpp--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies a list of IP addresses indicating + NTP (RFC 1035) servers available to the client. Servers + should be listed in order of preference. + + ooppttiioonn nneettbbiiooss--nnaammee--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... + ];; + + The NetBIOS name server (NBNS) option specifies a list of + RFC 1001/1002 NBNS name servers listed in order of prefer- + ence. + + + + 17 + + + + + + dhcpd.conf(5) dhcpd.conf(5) + + + ooppttiioonn nneettbbiiooss--dddd--sseerrvveerr _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + The NetBIOS datagram distribution server (NBDD) option + specifies a list of RFC 1001/1002 NBDD servers listed in + order of preference. + + ooppttiioonn nneettbbiiooss--nnooddee--ttyyppee _u_i_n_t_8;; + + The NetBIOS node type option allows NetBIOS over TCP/IP + clients which are configurable to be configured as + described in RFC 1001/1002. The value is specified as a + single octet which identifies the client type. A value of + 1 corresponds to a NetBIOS B-node; a value of 2 corre- + sponds to a P-node; a value of 4 corresponds to an M-node; + a value of 8 corresponds to an H-node. + + ooppttiioonn nneettbbiiooss--ssccooppee _s_t_r_i_n_g;; + + The NetBIOS scope option specifies the NetBIOS over TCP/IP + scope parameter for the client as specified in RFC + 1001/1002. See RFC1001, RFC1002, and RFC1035 for charac- + ter-set restrictions. + + ooppttiioonn ffoonntt--sseerrvveerrss _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies a list of X Window System Font + servers available to the client. Servers should be listed + in order of preference. + + ooppttiioonn xx--ddiissppllaayy--mmaannaaggeerr _i_p_-_a_d_d_r_e_s_s [,, _i_p_-_a_d_d_r_e_s_s ... ];; + + This option specifies a list of systems that are running + the X Window System Display Manager and are available to + the client. Addresses should be listed in order of pref- + erence. + + ooppttiioonn ddhhccpp--cclliieenntt--iiddeennttiiffiieerr _d_a_t_a_-_s_t_r_i_n_g;; + + This option can be used to specify the a DHCP client iden- + tifier in a host declaration, so that dhcpd can find the + host record by matching against the client identifier. + + SSEEEE AALLSSOO + dhcpd.conf(5), dhcpd.leases(5), draft-ietf-dhc- + options-1533update-04.txt, draft-ietf-dhc-dhcp-07.txt. + + AAUUTTHHOORR + ddhhccppdd((88)) was written by Ted Lemon under a + contract with Vixie Labs. Funding for this project was + provided by the Internet Software Corporation. Informa- + tion about the Internet Software Consortium can be found + at hhttttpp::////wwwwww..iisscc..oorrgg//iisscc.. + + + + + + 18 + + diff -rNc2 DHCPD-BETA-5.16/dhcpd.leases.5 DHCPD-BETA-5.17/dhcpd.leases.5 *** DHCPD-BETA-5.16/dhcpd.leases.5 Wed Dec 31 16:00:00 1969 --- DHCPD-BETA-5.17/dhcpd.leases.5 Fri Nov 21 22:51:08 1997 *************** *** 0 **** --- 1,82 ---- + .\" dhcpd.conf.5 + .\" + .\" Copyright (c) 1997 The Internet Software Consortium. + .\" All rights reserved. + .\" + .\" Redistribution and use in source and binary forms, with or without + .\" modification, are permitted provided that the following conditions + .\" are met: + .\" + .\" 1. Redistributions of source code must retain the above copyright + .\" notice, this list of conditions and the following disclaimer. + .\" 2. Redistributions in binary form must reproduce the above copyright + .\" notice, this list of conditions and the following disclaimer in the + .\" documentation and/or other materials provided with the distribution. + .\" 3. Neither the name of The Internet Software Consortium nor the names + .\" of its contributors may be used to endorse or promote products derived + .\" from this software without specific prior written permission. + .\" + .\" THIS SOFTWARE IS PROVIDED BY THE INTERNET SOFTWARE CONSORTIUM AND + .\" CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, + .\" INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF + .\" MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + .\" DISCLAIMED. IN NO EVENT SHALL THE INTERNET SOFTWARE CONSORTIUM OR + .\" CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, + .\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT + .\" LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF + .\" USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + .\" ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + .\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + .\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + .\" SUCH DAMAGE. + .\" + .\" This software has been written for the Internet Software Consortium + .\" by Ted Lemon in cooperation with Vixie + .\" Enterprises. To learn more about the Internet Software Consortium, + .\" see ``http://www.isc.org/isc''. To learn more about Vixie + .\" Enterprises, see ``http://www.vix.com''. + .TH dhcpd.leases 5 + .SH NAME + dhcpd.leases - DHCP client lease database + .SH DESCRIPTION + The Internet Software Consortium DHCP Server keeps a persistent + database of leases that it has assigned. This database is a free-form + ASCII file containing one valid declaration per lease. If more than + one declaration appears for a given lease, the last one in the file is + used. The file is written as a log, so this is not an unusual + occurrance. + .PP + When dhcpd is first installed, there is no lease database. However, + dhcpd requires that a lease database be present before it will start. + To make the initial lease database, just create an empty file called + DBDIR/dhcpd.leases. + .PP + In order to prevent the lease database from growing without bound, the + file is rewritten from time to time. First, a temporary lease + database is created and all known leases are dumped to it. Then, the + old lease database is renamed DBDIR/dhcpd.leases~. Finally, the + newly written lease database is moved into place. + .PP + There is a window of vulnerability where if the dhcpd process is + killed or the system crashes after the old lease database has been + renamed but before the new one has been moved into place, there will + be no DBDIR/dhcpd.leases. In this case, dhcpd will refuse to start, + and will require manual intervention. \fBDO NOT\fR simply create a + new lease file when this happens - if you do, you will lose all your + old bindings, and chaos will ensue. Instead, rename + DBDIR/dhcpd.leases~ to DBDIR/dhcpd.leases, restoring the old, valid + lease file, and then start dhcpd. This guarantees that a valid lease + file will be restored. + .SH FORMAT + The format of the lease declarations is not currently documented. + .SH FILES + .B DBDIR/dhcpd.leases + .SH SEE ALSO + dhcpd(8), dhcp-options(5), dhcpd.conf(5), RFC2132, RFC2131. + .SH AUTHOR + .B dhcpd(8) + was written by Ted Lemon + under a contract with Vixie Labs. Funding + for this project was provided by the Internet Software Corporation. + Information about the Internet Software Consortium can be found at + .B http://www.isc.org/isc. Binary files DHCPD-BETA-5.16/dhcpxlt and DHCPD-BETA-5.17/dhcpxlt differ diff -rNc2 DHCPD-BETA-5.16/dispatch.c DHCPD-BETA-5.17/dispatch.c *** DHCPD-BETA-5.16/dispatch.c Fri Nov 8 12:06:29 1996 --- DHCPD-BETA-5.17/dispatch.c Sat Nov 29 00:04:30 1997 *************** *** 43,47 **** #ifndef lint static char copyright[] = ! "$Id: dispatch.c,v 1.27 1996/11/08 20:06:29 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ --- 43,47 ---- #ifndef lint static char copyright[] = ! "$Id: dispatch.c,v 1.27.2.2 1997/11/29 08:04:30 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ *************** *** 351,356 **** /* Not likely to be transitory... */ ! if (count < 0) ! error ("poll: %m"); i = 0; --- 351,360 ---- /* Not likely to be transitory... */ ! if (count < 0) { ! if (errno == EAGAIN || errno == EINTR) ! continue; ! else ! error ("poll: %m"); ! } i = 0; *************** *** 381,393 **** int count; - FD_ZERO (&r); FD_ZERO (&w); FD_ZERO (&x); do { /* Set up the read mask. */ for (l = interfaces; l; l = l -> next) { FD_SET (l -> rfdesc, &r); - FD_SET (l -> rfdesc, &x); if (l -> rfdesc > max) max = l -> rfdesc; --- 385,397 ---- int count; FD_ZERO (&w); FD_ZERO (&x); do { + FD_ZERO (&r); + /* Set up the read mask. */ for (l = interfaces; l; l = l -> next) { FD_SET (l -> rfdesc, &r); if (l -> rfdesc > max) max = l -> rfdesc; diff -rNc2 DHCPD-BETA-5.16/memory.c DHCPD-BETA-5.17/memory.c *** DHCPD-BETA-5.16/memory.c Sat Mar 29 00:15:35 1997 --- DHCPD-BETA-5.17/memory.c Fri Nov 21 23:02:39 1997 *************** *** 43,47 **** #ifndef lint static char copyright[] = ! "$Id: memory.c,v 1.22.2.1 1997/03/29 08:15:35 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ --- 43,47 ---- #ifndef lint static char copyright[] = ! "$Id: memory.c,v 1.22.2.3 1997/11/22 07:02:39 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ *************** *** 455,460 **** if (!(lease -> flags & ABANDONED_LEASE) && comp -> ends > cur_time && ! ((comp -> uid && (lease -> uid || ! !(lease -> flags & DYNAMIC_BOOTP_OK)) && (comp -> uid_len != lease -> uid_len || memcmp (comp -> uid, lease -> uid, comp -> uid_len))) || --- 455,459 ---- if (!(lease -> flags & ABANDONED_LEASE) && comp -> ends > cur_time && ! (((comp -> uid && lease -> uid) && (comp -> uid_len != lease -> uid_len || memcmp (comp -> uid, lease -> uid, comp -> uid_len))) || diff -rNc2 DHCPD-BETA-5.16/print.c DHCPD-BETA-5.17/print.c *** DHCPD-BETA-5.16/print.c Tue Aug 27 02:53:30 1996 --- DHCPD-BETA-5.17/print.c Sat Nov 29 00:05:31 1997 *************** *** 43,47 **** #ifndef lint static char copyright[] = ! "$Id: print.c,v 1.11 1996/08/27 09:53:30 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ --- 43,47 ---- #ifndef lint static char copyright[] = ! "$Id: print.c,v 1.11.2.1 1997/11/29 08:05:31 mellon Exp $ Copyright (c) 1995, 1996 The Internet Software Consortium. All rights reserved.\n"; #endif /* not lint */ *************** *** 62,66 **** s = habuf; for (i = 0; i < hlen; i++) { ! sprintf (s, "%x", data [i]); s += strlen (s); *s++ = ':'; --- 62,66 ---- s = habuf; for (i = 0; i < hlen; i++) { ! sprintf (s, "%02x", data [i]); s += strlen (s); *s++ = ':';