Re: ping, ssh not using dns?
Aaron <[email protected]> Tue, 09 Jun 2009 06:38:53 -0600
| Newsgroups | gmane.org.user-groups.nmlug |
|---|---|
| Message-ID | <[email protected]> |
Nick Frost wrote:
> On Jun 7, 2009, at 6:46 AM, Aaron wrote:
>
>> I'm using netmanager over wireless on eeebuntu at home.
>> the 'host' command seems to do host name lookups, but
>> other commands, like ping and ssh do not.
>>
>> why might this occur?
>>
>> flea:~> cat /etc/resolv.conf
>> # Generated by NetworkManager
>> domain localnet
>> search localnet
>> nameserver 192.168.1.1
>> flea:~> host coot
>> coot has address 192.168.1.1
>> flea:~> ping coot
>> ping: unknown host coot
>
> What is the output of;
>
> grep -i hosts /etc/nsswitch.conf ?
hosts: dns files mdns4_minimal [NOTFOUND=return] mdns4
>
> e.g.
>
> grep dns /etc/nsswitch.conf
> # dns Use DNS (Domain Name Service)
> #hosts: db files nisplus nis dns
> hosts: files dns
>
> Also, do you have an entry for coot in your local /etc/hosts file?
>
no. I was hoping that since it knows that coot is the DNS server
(running dnsmasq) coot could resolve it's own name
> 192.168.1.1 coot.boim.com coot
>
> and what is the local domain name set to? (dnsdomainname)
>
localnet
note:
root@flea:~/.ssh# ping coot.localnet
ping: unknown host coot.localnet
root@flea:~/.ssh# host coot.localnet
Host coot.localnet not found: 3(NXDOMAIN)
root@flea:~/.ssh# host coot.localnet 192.168.1.1
Using domain server:
Name: 192.168.1.1
Address: 192.168.1.1#53
Aliases:
Host coot.localnet not found: 3(NXDOMAIN)
>
> It may be that your local machine thinks it has a different domain
> name than that which your local nameserver is returning for the query
> and SSH and/or ping are finding a mismatch with the dnsdomain name and
> think coot belongs to a different network.
coot has no response to dnsdomainname.
resolv.conf has only one line... nameserver 127.0.0.1
here are some curious lines in dnsmasq.conf:
# Never forward plain names (without a dot or domain part)
domain-needed
# Never forward addresses in the non-routed address spaces.
#bogus-priv
# Add other name servers here, with domain specs if they are for
# non-public domains.
#server=/localnet/192.168.0.1
#server=/localnet/192.168.1.2
#server=/localnet/192.168.1.1
server=/localnet/127.0.0.1
server=/1.168.192.in-addr.arpa/127.0.0.1
server=/0.0.10.in-addr.arpa/127.0.0.1
server=216.184.2.2
server=198.59.115.2
# Add local-only domains here, queries in these domains are answered
# from /etc/hosts or DHCP only.
local=/localnet/
domain=localnet
thx,
aaron
_______________________________________________
NMLUG mailing list
[email protected]
http://lists.b9.com/cgi-bin/mailman/listinfo/nmlug