Fixed and dynamic IPs in ISC DHPD lead to double lease
- by GorillaPatch
I would like to have a small dynamic adress part and the most clients are assigned a fixed IP adress.
My dhcpd.conf looks like this:
use-host-decl-names on;
authoritative;
allow client-updates;
ddns-updates on;
# Einstellungen fuer DHCP leases
default-lease-time 3600;
max-lease-time 86400;
lease-file-name "/var/lib/dhcpd/dhcpd.leases";
subnet 192.168.11.0 netmask 255.255.255.0 {
ddns-updates on;
pool {
# IP range which will be assigned statically
range 192.168.11.1 192.168.11.240;
deny all clients;
}
pool {
# small dynamic range
range 192.168.11.241 192.168.11.254; # used for temporary devices
}
}
group {
host pc1 {
hardware ethernet xx:xx:xx:xx:xx:xx;
fixed-address 192.168.11.11;
}
}
The motivation for the pool declaration with deny all hosts comes from the ISC DHCPD homepage http://www.isc.org/files/auth.html This will allow hosts to be first added to the network, where they will receive a temporary IP from the 241-254 adress range and then later write an explicit host declaration. Upon next connect it will receive the right configuration.
The problem is that I am getting error messages that 192.168.11.13 has a dynamic and a static lease. I am a bit confused as I expected the pool declaration with deny all clients would not count as dynamic.
Dynamic and static leases present for 192.168.11.13.
Remove host declaration pc1 or remove 192.168.11.13
from the dynamic address pool for 192.168.11.0/24
Is there a way to have the DHCP server send an DHCPNA to clients if they have a host statement and retain this dynamic range?