[Dnsmasq-discuss] dnsmasq for road warriors

richardvoigt at gmail.com richardvoigt at gmail.com
Sat Nov 10 23:46:10 GMT 2012


no-resolv is doing more harm than good.

dnsmasq is smart enough to ignore 127.0.0.1 in /etc/resolv.conf  And it
will automatically pick up DHCP-assigned DNS servers which are written
there.  Some DHCP clients have an option to update a different file with
the DNS servers, in that case use dnsmasq's resolv-file option.


On Sat, Nov 10, 2012 at 9:54 AM, /dev/rob0 <rob0 at gmx.co.uk> wrote:

> Seems to me that dnsmasq is a better nscd replacement, and it has a
> place in mobile computing.
>
> # we use this dnsmasq as this system's own resolver
> no-resolv
> # I'm not sure if both of these are needed; we only want DNS and
> # only on loopback; we serve only this machine.
> no-dhcp-interface=lo
> listen-address=127.0.0.1
> user=dnsmasq
> group=dnsmasq
> # When connected to VPN, these names/addresses resolve. When not
> # connected, they don't, but that's okay, because we can't get to
> # them anyway.
> server=/rob0.vpn/192.168.6.1
> server=/6.168.192.in-addr.arpa/192.168.6.1
> # upstream: Google Public DNS
> server=8.8.4.4
>
> The problem here is when you might not want to use 8.8.4.4, such as
> when you're at a dnsmasq site where internal DNS is working. The
> solution, I guess, would be a hook in the DHCP client to write the
> DHCP-obtained nameserver[s] to a dnsmasq.d/file to include, and
> signal or restart dnsmasq.
>
> Problem with that solution: will dnsmasq.d get crufty, or do we just
> reuse the same file? Also, what if one of the mobile connections is
> not handled by DHCP, such as some cellular data connections?
>
> Speaking of cruft, maybe that's not a bad thing? What will dnsmasq do
> with multiple upstream servers?
>
> server=192.168.40.1
> server=192.168.0.1
> server=192.168.1.1
> server=8.8.4.4
>
> When we're at a site where one of those is our router, that should
> respond much faster than 8.8.4.4 can. OTOH, it could cause
> intermittent errors with local names; 8.8.4.4 is not going to know
> "minipax.rob0.lan".
>
> Can we priortise upstream servers? --all-servers implies that this
> can be done somehow, but I don't know how ... is it merely the order
> in which they are listed in the config (or on the command line)? When
> not using --all-servers, how does dnsmasq decide when to try a
> different one, and which one will be tried in that case? Random
> selection, rotating sequential, fixed top-down priority?
>
> Ideally we'd want something which you set up one time and is mostly
> done; something that should work at regular sites you frequent, as
> well as most public hotspots.
> --
>   http://rob0.nodns4.us/ -- system administration and consulting
>   Offlist GMX mail is seen only if "/dev/rob0" is in the Subject:
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.thekelleys.org.uk/pipermail/dnsmasq-discuss/attachments/20121110/93613410/attachment.html>


More information about the Dnsmasq-discuss mailing list