[Dnsmasq-discuss] inconsistence between dhcp-hosts and dhcp-hostsfile

Andreas Kuropka andreas at kuropka.eu
Fri Jun 27 14:26:46 UTC 2025


I am using dnsmasq 2.91 un a Raspberry Pi 5 (Arch Linux Arm). To declutter my config I have moved my dhcp-hosts to a dhcp-hostsfile and found an inconsistency.

While in the config a declaration such as dhcp-hosts=AA:BB:CC:DD:EE:FF,set:name still considers the settings in the system hosts/ethers-file for IP-assignment a declaration in a hostsfile of AA:BB:CC:DD:EE:FF,set:name gives the device a new IP (.42 instead of .11) and logs:

Jun 27 16:05:17 raspberry dnsmasq-dhcp[419]: Name iPhone wurde dem DHCP-Lease von 192.168.188.42 nicht zugewiesen, da der Name in /etc/hosts bereits mit Adresse 192.168.188.11 existiert

Aside of the IP everything works, dhcp-options defined in an optsfile are respected. This would confirm MAC-address is correct (it was also copied/pasted while transferring to new files).

Adding the desired IP to the dhcp-hostsfile (AA:BB:CC:DD:EE:FF,set:name,1.2.3.4) resolves the problem but this would be a double configuration. Also, there's then a warning logged:

Jun 27 16:21:28 raspberry dnsmasq-dhcp[410]: doppelte IP-Adresse 192.168.188.15 (iphone12) in "dhcp-config"-Anweisung

Please have a look, thank y




More information about the Dnsmasq-discuss mailing list