On 12/9/05, michael higgins <[EMAIL PROTECTED]> wrote:
> I've found that it'll often takes longer to get DNS resolution than content 
> over my connection, so I thought a caching DNS server the way to go. With 
> that in mind, I installed BIND.

nscd does this, and is much simpler.  It is already installed as part
of glibc.  Just do rc-update -a nscd default.

> From what I understand (right or wrong, IDK), I should only have to look up 
> something once, then that info is available locally until I reboot. Or, like 
> that...

It will cache until named is restarted, or the lookup expires.  The
lookup expiration time is determined by the authoritative name server
for that domain.

> So, how do I know if this is doing what I want? If anyone knows the right and 
> proper way to do this, I'd appreciate it.

>From one terminal:

tcpdump dst port 53

>From another terminal:

ping -c 4 google.com
ping -c 4 google.com

If you see domain queries being sent when you do the second ping, then
you are not caching.

BTW, if you really want to use named for this, your /etc/resolv.conf
should contain only "nameserver 127.0.0.1".  If you are use nscd, then
resolv.conf can be left as is.

-Richard

-- 
gentoo-user@gentoo.org mailing list

Reply via email to