Hi,<div><br></div><div><br></div><div>My proposal can integrate easily with NetworkManager. It is requires a single line change in /etc/dhcp3/dhclient.conf:</div><div><br></div><div>prepend domain-name-servers 127.0.0.1;</div>
<div><br></div><div>This will make NetworkManager to always add 127.0.0.1 as the first DNS server and all DNS servers it will receive by DHCP will be added below 127.0.0.1 in /etc/resolv.conf</div><div><br></div><div>So, to implement my proposal, the following simple tasks should be done:</div>
<div><br></div><div>1) Add dnsmasq or nscd as a package to be installed by default in Ubuntu</div><div>2) Change a single line in /etc/dhcp3/dhclient.conf as a mentioned.</div><div><br></div><div>And voi lá! DNS cache by default. There are several blogs in the internet teaching how to manually create a DNS cache. I'll point <a href="http://embraceubuntu.com/2006/08/02/local-dns-cache-for-faster-browsing/">http://embraceubuntu.com/2006/08/02/local-dns-cache-for-faster-browsing/</a> as an example.</div>
<div><br></div><div><br></div><div>I personally see this so easy to implement that DNS cache could be activade since Ubuntu 10.10.</div><div><br></div><div><br></div><div>Thanks for all your comments,</div><div><br></div>
<div><br></div><div>Kurt Kraut</div><meta http-equiv="content-type" content="text/html; charset=utf-8"><meta http-equiv="content-type" content="text/html; charset=utf-8"><div><br><div class="gmail_quote">2010/6/2 Conn O'Griofa <span dir="ltr"><<a href="mailto:connogriofa@gmail.com">connogriofa@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Kurt,<br>
<div class="im"><br>
> I've been using dnsmasq (a lightweight alternative) on my computers to do the job and it works great. By default, dnsmasq only replies to <a href="http://127.0.0.1:53" target="_blank">127.0.0.1:53</a> request, so this wouldn't introduce security weakness.<br>
><br>
> Besides having a DNS cache (like dnsmasq) installed by default, the dhclient add 127.0.0.1 as the first name server in /etc/resolv.conf.<br>
><br>
> openSUSE is the only Linux distribution that has a DNS cache out of the box. They just provide the nscd package installed by default.<br>
><br>
> This is a pretty easy, simple, powerful feature. I strongly recommend it to be implemented."<br>
><br>
> How can I truly submit this proposal? My blueprint has been untouched and unread for the last yo years.<br>
<br>
</div>I would like to add my support for this idea. I (and I assume several<br>
others) have problems with slow DNS lookups on my Ubuntu installations<br>
when compared to Windows; see bug #94940 [1]. Perhaps a DNS caching<br>
server such as dnsmasq would alleviate the symptoms of that bug.<br>
<br>
However, if dnsmasq were to be integrated into the default<br>
installation (and the package was pre-configured as per the dnsmasq<br>
wiki's instructions [2]), there would be a conflict with<br>
NetworkManager.<br>
<br>
As you can see from the community instructions, you need to edit your<br>
/etc/resolv.conf and add the local machine's address (127.0.0.1) as<br>
your first nameserver. This is a problem because any changes to this<br>
file will be overwritten by NetworkManager each time it initializes a<br>
new connection (which is warned in the commented section of the file).<br>
The only solution that I am aware of, is to edit your active network<br>
connection in NetworkManager's applet, change the setting from<br>
"Automatic (DHCP)" to "Automatic (DHCP) addresses only", and then<br>
manually input your DNS servers like so: "127.0.0.1, <your regular DNS<br>
server 1>, <your regular DNS server 1>".<br>
<br>
If we are going to integrate dnsmasq into the default installation it<br>
may serve us better to investigate the possibility of adding some kind<br>
of autodetection of the presence of dnsmasq to NetworkManager itself.<br>
We cannot expect users to manually edit their network connections for<br>
each new installation (or indeed, each new wireless network profile<br>
they create).<br>
<br>
Let me also mention that dnsmasq has the capability of providing ICS<br>
(internet connection sharing) [3]. This would be an excellent feature<br>
to add to NetworkManager's graphical interface, which is yet another<br>
feature that competing operating systems provide by default.<br>
<br>
Thanks,<br>
Conn<br>
<br>
[1] <a href="https://bugs.launchpad.net/ubuntu/+source/nss-mdns/+bug/94940" target="_blank">https://bugs.launchpad.net/ubuntu/+source/nss-mdns/+bug/94940</a><br>
[2] <a href="https://help.ubuntu.com/community/Dnsmasq" target="_blank">https://help.ubuntu.com/community/Dnsmasq</a><br>
[3] <a href="https://help.ubuntu.com/community/Internet/ConnectionSharing" target="_blank">https://help.ubuntu.com/community/Internet/ConnectionSharing</a><br>
</blockquote></div><br></div>