Bug 104143 - Ping (and other things) don't obey "search" directive in /etc/resolv.conf
Summary: Ping (and other things) don't obey "search" directive in /etc/resolv.conf
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 2.1
Classification: Red Hat
Component: iputils
Version: 2.1
Hardware: i386
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Phil Knirsch
QA Contact: Mike McLean
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-09-10 14:24 UTC by Christopher C. Weis
Modified: 2015-03-05 01:12 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2003-09-10 17:56:58 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Christopher C. Weis 2003-09-10 14:24:27 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.2.1) Gecko/20030225

Description of problem:
When trying to ping <hostname>.<somedomain>.<somesuperdomain> using only
<hostname>, ping doesn't resolv <hostname>, even though
<somedomain>.<somesuperdomain> is listed in /etc/resolv.conf after the "search"
directive.

Example:

Let's say we have a machine named host1.mydomain.net.  If I ping
"host1.mydomain.net", it succeeds.  If I try to ping "host1", it fails, even
though in /etc/resolv.conf, I have "search mydomain.net" listed.

/etc/nsswitch.conf:

hosts:      files dns


/etc/host.conf:

order hosts,bind

This seems to be the case with other tools (such as traceroute, ssh, telnet, etc.)

Both "nslookup" and "host" do work correctly.  I.e., both "host
host1.mydomain.net" and "host host1" work.


Version-Release number of selected component (if applicable):
iputils-20001110-6.AS21.2

How reproducible:
Always

Steps to Reproduce:
1. Add the "domainname" part of a hosts's FQDN into /etc/resolv.conf's "search"
field.
2. "ping <nodename>", where nodename is the node part of the host's FQDN
3. 
    

Actual Results:  (edited to remove real hostnames and IPs)

[root@serv02 root]# ping tarragon
ping: unknown host tarragon
[root@serv02 root]# host tarragon
tarragon.<mydomain> has address aaa.bbb.ccc.yyy

Expected Results:  ( from an identically configured RH9 machine )

[root@test03 tmp]# ping tarragon
PING tarragon.<mydomain> (aaa.bbb.ccc.ddd) 56(84) bytes of data.
64 bytes from tarragon.<mydomain> (aaa.bbb.ccc.ddd): icmp_seq=2 ttl=255 time=2.95 ms
64 bytes from tarragon.<mydomain> (aaa.bbb.ccc.ddd): icmp_seq=3 ttl=255
time=0.188 ms

Additional info:

Every machine that we have uses this same type of configuration and they all
work... except for the RH 2.1ES server.  I'm currently loading up another RH
2.1ES machine to do some more testing.

Comment 1 Christopher C. Weis 2003-09-10 17:56:58 UTC
Ahhh... It's called nscd, and it needs to be restarted after changes are made to
/etc/resolv.conf

Silly me...


Note You need to log in before you can comment on or make changes to this bug.