On Saturday 17 April 2004 00:33, gerald.maricau@versateladsl.be wrote:
I'm wondering that the resolution is't functioning when i put a pair of IP-address/name in the file /etc/hosts I'm using SuSE 9.0 or SuSE 8.1 and have the same problem/error. The configuration files seems correct:
/etc/nsswitch.conf= hosts: files dns
/etc/host.conf= order hosts, bind
/etc/hosts= 10.100.0.1 hello
/etc/sysconfig/suseconfig= CHECK_ETC_HOSTS="yes" BEAUTIFY_ETC_HOSTS="yes"
and the used command is = $ host hello. Host hello not found: 3(NXDOMAIN)
the 'host' command will always use DNS servers, it doesn't even look at nsswitch.conf. From the man page <quote> DESCRIPTION host is a simple utility for performing DNS lookups. </quote> To see, try something like strace host hello 2>&1|grep nsswitch and then try strace ping hello 2>&1|grep nsswitch "ping hello" should correctly ping 10.100.0.1