[Dnsmasq-discuss] same DHCP client on multiple interfaces

Hamish Moffatt hamish at moffatt.email
Mon Aug 29 08:43:05 UTC 2022


I've got dnsmasq listening on multiple interfaces (two VLANs), and at 
least one client that is also on both VLANs at once. The client has the 
same MAC address on both VLANs. I'd like to assign an IP address on each 
VLAN via DHCP.

I have the following in my config:

dhcp-host=38:C9:86:40:86:37,192.168.42.18,[::0:18],potoroo
dhcp-host=38:C9:86:40:86:37,192.168.66.18,potoroo-iotlan

dnsmasq (v2.80, in OpenWRT 19.07) seems to allocate the IP addresses ok, 
but only the most recently leased hostname requested works.


Renewing shows

Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPREQUEST(br-lan) 192.168.42.18 38:c9:86:40:86:37
Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPNAK(br-lan) 192.168.42.18 38:c9:86:40:86:37 wrong address
Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPDISCOVER(br-lan) 192.168.42.18 38:c9:86:40:86:37
Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPOFFER(br-lan) 192.168.42.18 38:c9:86:40:86:37
Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPREQUEST(br-lan) 192.168.42.18 38:c9:86:40:86:37
Mon Aug 29 18:40:48 2022 daemon.info dnsmasq-dhcp[29928]: 
DHCPACK(br-lan) 192.168.42.18 38:c9:86:40:86:37 potoroo


Should this work? Or would it be easier to override the MAC address on 
the client for one VLAN?


thanks

Hamish




More information about the Dnsmasq-discuss mailing list