[Dnsmasq-discuss] Trailing dots and the way dnsmasq handles hosts
Eric S. Johansson
Sat, 09 Apr 2005 07:02:36 -0400
John Drake wrote:
> I have a not so serious question/problem regarding dnsmasq.
> I'm new here so I must say that this dns server is by far the best one
> ever made for local networks. Anyways let me get to the point. I have
> a bunch of hostnames setup in /etc/hosts on my slackware box and
> dnsmasq seems to be relaying that info just fine except for one minor
> I can only ping it if I add a trailing . such as "ping maclap." and
> "ping maclap" won't work (this is from client machines). I can run
> "nslookup maclap" and it returns the correct ip. So my question is
> obvious now, is there a way to ping local machines by their hostname
> without the dot? It works with nslookup and dig but not with anything
if I understand you correctly, you want to be able to just refer to
hosts by short name (xeno vrs xeno.harvee.org to give a real example)
without a trailing ".".
I think this is what I did (and I will send you my dnsmasq configuration
I think the essential elements are expand-hosts and domain. Between
those two, any incomplete name will be expanded to a fully qualified
domain name and therefore be resolved.
192.168.25.102 igs-xeno inguide.com. www.inguide.com.
as you can see, I dotted the fully qualified names and left the short
names un-dotted. it's been awhile since I have read the documentation
so I'm not sure if that is necessary. It may be just left over scar
tissue from working with bind.
and yes like you, I have found this to be a wonderful name server for
small networks like mine (six real machines, five virtual)
The result of the duopoly that currently defines "competition" is that
prices and service suck. We're the world's leader in Internet
technology - except that we're not.