[Dnsmasq-discuss] resolving on dnsmasq box itself?

Bart Vandewoestyne Bart.Vandewoestyne at telenet.be
Tue Jun 12 15:35:57 BST 2007

Dear all,

I have a NAT-box setup with iptables masquerading to masquerade
out my personal internal home-LAN.  This box is called 'forsythe'
and has an internal IP of  The external interface is
configued with DHCP by the DHCP-server from my ISP.

I am using this version of dhclient on my Debian GNU/Linux stable

forsythe:~# dhclient -V       
Internet Systems Consortium DHCP Client V3.0.4

I have the following in my /etc/dhcp3/dhclient.conf file:

request subnet-mask, broadcast-address, time-offset, routers,
        domain-name, domain-name-servers, host-name,
        netbios-name-servers, netbios-scope, interface-mtu;

After I have obtained an IP-address on my external interface, my
/etc/resolc.conf contains the following lines:

search telenet.be

I have the following options in my /etc/dnsmasq.conf file:


and in my /etc/hosts I have as only line:       localhost

Furthermore, I have

forsythe:~# cat /etc/hostname 

So far so good... i can ping and do nslookup for for example www.google.com
but my question is about the following:

The hostname of my masquerading (NAT) box which also runs the dnsmasq
daemon is 'forsythe' and it has a statically assigned ip address of  However, i cannot ping or do nslookup of the host 'forsythe':

forsythe:~# ping forsythe
ping: unknown host forsythe
forsythe:~# ping forsythe.
ping: unknown host forsythe.
forsythe:~# nslookup forsythe

Non-authoritative answer:
*** Can't find forsythe: No answer

forsythe:~# nslookup forsythe.

** server can't find forsythe: NXDOMAIN

Can somebody tell me what the *CLEAN* solution is to overcome this problem?

If i add the line     forsythe.localnet       forsythe


ping forsythe

works but the following commands fail:

nslookup forsythe
nslookup forsythe.
ping forsythe.

What is the clean solution to be able to ping and do nslookups
for the host 'forsythe'?

I also thought of adding a line

prepend domain-name-servers;

to my /etc/dhcp3/dhclient.conf so that my /etc/resolv.conf has an extra


but I don't think this is the proper way to do it... it looks like I'm putting
dnsmasq in a loop this way...

Any suggestions for a *CLEAN* solution are welcome!

	"Share what you know.  Learn what you don't."

More information about the Dnsmasq-discuss mailing list