ISC DHCP DNS Update Problem
Beim Betrieb des ISC- DHCP Servers kann es vorkommen, dass trotz aktiviertem dynamischen DNS Update, die DNS Einträge nicht geschrieben werden.In der man- Page findet man hierzu:
"...
In addition to these differences, the server also does not update very aggressively. Because each DNS update involves a round trip to the DNS server, there is a cost associated with doing updates even if they do not actually modify the DNS database.
So the DHCP server tracks whether or not it has updated the record in the past (this information is stored on the lease) and does not attempt to update records that it thinks it has already updated.
This can lead to cases where the DHCP server adds a record, and then the record is deleted through some other mechanism, but the server never again updates the DNS because it thinks the data is already there. In this case the data can be removed from the lease through operator intervention, and once this has been done, the DNS will be updated the next time the client renews.
..."
Die Behebung ist an sich recht einfach:
# service isc-dhcp-server stopDie Pfade, sowie die Befehle sind hierbei an ein Ubuntu System angelehnt. Nach dem Stoppen des DHCP Servers wird in das Verzeichnis gewechselt, in dem die lease- Datei zu finden ist. Dort werden mittels eines SED- Befehls alle Zeilen, die mit "set ddns" beginnen, ersatzlos gelöscht. Die Ergebnisdatei wird dann als Lease-File für den nächsten Start benutzt.
# cd /var/lib/dhcp
# cat dhcpd.leases | sed '/^ set ddns/ d' > leases.temp
# mv leases.temp dhcpd.leases
# service isc-dhcp-server start
Nachdem die Clients erneut beim DHCP- Server anfragen, werden nun auch wieder die DNS- Einträge geschrieben. Im Logfile des DHCP-Servers finden sich Einträge "Added new forward map from..." und "Added reverse map from..."