On Fri, 27 Jul 2012 09:45:02 -0500, Kent West wrote:

> Why can I ping the hostname, but not the fully-qualified domain name of
> a box?
>
> westk@westek:~$ ping k1000
> PING k1000.acu.local (150.252.149.1) 56(84) bytes of data. 64 bytes from
> 150.252.149.1: icmp_req=1 ttl=62 time=0.128 ms ^C64 bytes from
> 150.252.149.1: icmp_req=2 ttl=62 time=0.138 ms
> 
> --- k1000.acu.local ping statistics --- 2 packets transmitted, 2
> received, 0% packet loss, time 5002ms rtt min/avg/max/mdev =
> 0.128/0.133/0.138/0.005 ms

(...)

I remember something related to the "/etc/nsswitch.conf" file, the 
order of the queried facilities and also the avahi issue with ".local" 
domains...

sm01@stt008:~$ cat /etc/nsswitch.conf|grep hosts
hosts:          files mdns4_minimal [NOTFOUND=return] dns mdns4

And let's see if I can ping a local machine using its FQDN:

sm01@stt008:~$ ping -c 3 stt008.linux.site
PING stt008.linux.site (192.168.0.8) 56(84) bytes of data.
64 bytes from stt008.linux.site (192.168.0.8): icmp_seq=1 ttl=64 time=0.016 ms
64 bytes from stt008.linux.site (192.168.0.8): icmp_seq=2 ttl=64 time=0.007 ms
64 bytes from stt008.linux.site (192.168.0.8): icmp_seq=3 ttl=64 time=0.013 ms

--- stt008.linux.site ping statistics ---
3 packets transmitted, 3 received, 0% packet loss, time 1998ms
rtt min/avg/max/mdev = 0.007/0.012/0.016/0.003 ms

Yes, I can ping *but* I have the above machine listed in my "/etc/hosts" 
file.

sm01@stt008:~$ cat /etc/hosts
127.0.0.1       localhost
192.168.0.8     stt008.linux.site       stt008

# The following lines are desirable for IPv6 capable hosts
::1     localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts

Just for testing purposes yo can try with:

hosts:          files mdns4_minimal dns mdns4

Or:

hosts:          files dns mdns4_minimal [NOTFOUND=return] mdns4

(note: I'm sure this was documented in some place but can't find the source 
now)

Greetings,

-- 
Camaleón


-- 
To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org 
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org
Archive: http://lists.debian.org/juug00$2bd$1...@dough.gmane.org

Reply via email to