Introduction
This page describes how Alexis Huxley installed and configured his DHCP server.
Procedure
- Install the packages required for the DNS server by running:
apt -y install isc-dhcp-server
- Edit /etc/default/isc-dhcp-server and set:
INTERFACESv4="eth0"
- Reduce /etc/dhcp/dhcpd.conf to something like:
ddns-update-style none; authoritative; log-facility local7; # List known DHCP clients here #host halusky-eth0 { hardware ethernet dc:0e:a1:56:db:2e; fixed-address halusky.pasta.net; } subnet 192.168.1.0 netmask 255.255.255.0 { option domain-name "pasta.net"; option domain-name-servers 192.168.1.36; option ntp-servers time.pasta.net; option routers 192.168.1.51; # 1-5 are reserved # 6-50 is for statically configured hosts # 51-100 are for statically configured network equipment # 101-150 is for known hosts (known because they're declared in 'host' stanzas above) pool { range 192.168.1.101 192.168.1.150; allow known-clients; deny unknown-clients; } # 151-200 is for unknown clients (unknown because they're not declared in 'host' stanzas above) pool { range 192.168.1.151 192.168.1.200; allow unknown-clients; deny known-clients; } # 201-254 are reserved for future use }
- Start dhcpd with:
systemctl start isc-dhcp-server
- Run:
wget -qO - http://standards-oui.ieee.org/oui/oui.txt > /usr/local/etc/oui.txt
(Note that this URL is taken from BTS#963978..
- If there is an old dhcpd server on the network then stop it.
- Test as follows:
- Run:
tail -f /var/log/messages | grep dhcpd
- Connect a dynamic IP host to the network.
- Run:
dhcp-lease-list
Verify the manufacturer is specified.
- Run: