On 07/27/2012 11:35 AM, Camaleón wrote:
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,
westk@westek:~$ cat /etc/nsswitch.conf
# /etc/nsswitch.conf
#
# Example configuration of GNU Name Service Switch functionality.
# If you have the `glibc-doc-reference' and `info' packages installed, try:
# `info libc "Name Service Switch"' for information about this file.
passwd: compat
group: compat
shadow: compat
hosts: files mdns4_minimal [NOTFOUND=return] dns mdns4
networks: files
protocols: db files
services: db files
ethers: db files
rpc: db files
netgroup: nis
Changing the order of the hosts: line to:
hosts: files dns mdns4_minimal [NOTFOUND=return] mdns4
as you suggested above, seems to have solved the problem:
westk@westek:~$ ping k1000.acu.local
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.126 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 5001ms
rtt min/avg/max/mdev = 0.126/0.132/0.138/0.006 ms
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.135 ms
--- k1000.acu.local ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 5001ms
rtt min/avg/max/mdev = 0.128/0.131/0.135/0.012 ms
Will this cause me any problems?
--
Kent West<*)))><
http://kentwest.blogspot.com
Praise Yah! \o/
--
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/5012dee3.7020...@acu.edu