[Dnsmasq-discuss] dnsmasq as local DNS cache - scenario: notebook
with ppp/dhcp conigured links
Simon Kelley
simon at thekelleys.org.uk
Wed Feb 7 14:14:56 GMT 2007
Mateusz Korniak wrote:
> Hi !
> I am using dnsmasq as excellent dns speed up on my notebook.
> And it works great ! Big thanks to authors !
>
> I have only problem with dynamically created links.
>
> I made my dhcp client to overwrite /etc/resolv.conf every time link is
> configured with preadding 127.0.0.1 as nameserver in front of list.
> That fixed dhcp links but that trick does not work with ppp created (gprs -
> really slow ) links for me.
> As ppp stores it's dnses in /etc/ppp/resolv.conf when ppp link is created and
> no additions of nameservers seems to be possible.
>
> What is your sugestion for fixing that issue ?
>
> I was thinking about feature allowing to define many
> resolv-files
> and than:
> 1) use nameservers only from most recently updated file
We got there first. Exactly this feature is already in dnsmasq.
> 2) use namservers summed from all resolv-files (and filtering nameservers
> which are not accessible) ?
The best way to do this is to just put
nameserver 127.0.0.1
in /etc/resolv.conf; that should never change. Then make your
DHCP client write /etc/resolv.conf.dhcp or something similar. You
already found that pppd writes /etc/ppp/resolv.conf, so just put
resolv-file=/etc/resolv.conf.dhcp
resolv-file=/etc/ppp/resolv.conf
in /etc/dnsmasq.conf
Whichever file changed last will be used.
HTH
Simon.
>
>
> TIA for any comments, best regards,
More information about the Dnsmasq-discuss
mailing list