DHCP Ana Chanaba Robert Huylo
DHCP Background / Server dhcpd - Dynamic Host Configuration Protocol Server allows hosts on a TCP/IP network to request and be assigned IP addresses from a pool defined in dhcpd.conf adds lease concept to BOOTP predecessor
DHCP Background / Server reads dhcpd.conf and assembles list of addresses for use in subnet allocates address following request assigns a lease to client records lease in dhcpd.leases server can keep lease states across boots renews expired leases for clients
DHCP Background / Client dhcpcd – dhcp client gets host info (IP address, netmask, gateway, etc.) from a DHCP server lab1 – configures own network interface requests lease and lease renewals
DHCP Server Installation lab1.research.cs.uofs.edu Network Servers installation package dhcp
etc/dhcpd.conf option domain-name "lab1.research.cs.uofs.edu"; option domain-name-servers , ; default-lease-time 600; max-lease-time 7200; ddns-update-style ad-hoc; subnet netmask { range ; option routers ; }
Starting DHCP Server System Settings Server Settings Services dhcpd ** dhcrelay - dhcp servers on different subnets
var/lib/dhcp/dhcpd.leases lease { starts /03/01 18:45:39; ends /03/01 18:55:39; tstp /03/01 18:55:39; binding state free; hardware ethernet 00:c0:f0:30:d7:11; uid "\001\000\300\3600\327\021"; } lease { starts /03/03 03:01:59; ends /03/03 03:11:59; binding state active; next binding state free; hardware ethernet 00:e0:4c:96:f3:95; client-hostname "lab112.research.cs.uofs.edu"; }
References man pages – dhcpd.conf, dhcpcd, dhcpd, dhcpd.leases DHCP RFC 2131 & R. Droms DHCP HOWTO – Vladimir Vuksan Text – Chp. 13.7