[Dnsmasq-discuss] Problem getting dnsmasq to send a different default gateway to a host

Simon Kelley simon at thekelleys.org.uk
Tue Sep 4 16:58:17 BST 2012


On 03/09/12 22:17, Fadi wrote:
> Hello,
> 
> Please be kind this is my first posting to this list.
> 
> I have spent hours trying to get this to work, but I seem to be missing
> something.
> 
> I'm using the latest shibby build of TomatoUSB, and I want dnsmasq to send
> the default gateway and dns server address of 192.168.0.55 to the host
> whose
> MAC address is xx:xx:xx:xx:xx.
> 
> So I added this to the DNSmasq custom config:
> 
> 
> dhcp-mac=red,xx:xx:xx:xx:xx:xx
> dhcp-option=red,3,192.168.0.55
> dhcp-option=red,6,192.168.0.55
> 
> 
> This almost works. When I look at the DHCP OFFER packet in Wireshark,
> dnsmasq is sending TWO default gateway (option 3) addresses, the
> 192.168.0.55 I specified above PLUS the router's 192.168.0.1 address.
> 
> How can I prevent it from sending the router's IP as well? Some hosts on
> the
> network (tagged red) are using the 192.168.0.1 address as their default
> gateway and some are using the 192.168.0.55.
> 
> I have tried different permutations of using "tag:" and "set:" and "net:"
> always with the same result.
> 
> What am I doing wrong?
> 
> Thanks in advance.
> 

What version of dnsmasq are you using?

Have you tried setting --log-dhcp that will give you more information
about what exactly is happening.


Cheers,

Simon.





More information about the Dnsmasq-discuss mailing list