[Dnsmasq-discuss] dns-server in opts file doesn't work

Shixiong Shang sparkofwisdom.cloud at gmail.com
Tue Dec 17 17:38:02 GMT 2013


Hi, Simon:

Thanks a lot for checking this issue! Yes, the —dhcp-optsfile has /path/to/file. And here is the complete dump of the file:

tag:tag0,option:dns-server,8.8.8.8
tag:tag0,option:router,192.168.3.1
tag:tag1,option6:dns-server,[2001:4860:4860::8888]

Shixiong



On Dec 17, 2013, at 12:00 PM, Simon Kelley <simon at thekelleys.org.uk> wrote:

> On 17/12/13 12:30, Shixiong Shang wrote:
>> Hi, experts:
>> 
>> I tried to leverage opts file to modify the recursive dns server IP conveyed in RA. The entry in the opts file is shown below:
>> 
>> tag:tag1,option6:dns-server,[2001:4860:4860::8888]
>> 
>> I tcpdumped the outgoing RA message, but the dns server IP is still set to the IPv6 address dnsmasq bound to. However, if I use "--dhcp-option=tag:tag1,option6:dns-server,[2001:4860:4860::8888]” as an option in the CLI, then it worked in the way as expected.
>> 
>> Is there anything I did wrong in the opts file? It is still my preferred approach to use opts file.
> 
> I can't see any problem with that
> 
> Just to be sure, you're using --dhcp-optsfile=/path/to/file and the lines in /path/to/file are
> 
> tag:tag1,option6:dns-server,[2001:4860:4860::8888]
> 
> and _not_
> 
> dhcp-option=tag:tag1,option6:dns-server,[2001:4860:4860::8888]
> 
> and you remebered to restart dnsmasq or send SIGHUP after you altered the file?
> 
> That covers all the mistakes that people usually make with this.
> 
> 
> Cheers,
> 
> Simon.
> 
>> 
>> Thanks!
>> 
>> Shixiong
>> _______________________________________________
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss at lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>> 
> 
> 
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss




More information about the Dnsmasq-discuss mailing list