gethostbyname() and resolv.conf updates

Stephen Gallagher sgallagh at
Fri Jun 18 12:28:55 UTC 2010

On 06/17/2010 06:05 PM, Michal Schmidt wrote:
> On Thu, 17 Jun 2010 17:41:27 -0400 Bernie Innocenti wrote:
>> xchat in Fedora needs to be restarted after switching to a different
>> nameserver or it fails to resolve.
>> The xchat developers say that all xchat does is call gethostbyname().
>> A Debian user told me that Debian carries a glibc patch to make
>> processes notice resolv.conf updates and reload it.
>> Is there any chance we could apply the same patch in Fedora too? I
>> don't know all the details, but I guess there might be a good reason
>> why this patch wasn't upstreamed yet.
> Ulrich Drepper always said resolv.conf updates are detected fine when
> nscd is running, and that everyone should use it. There's a bug
> requesting nscd to be mandatory:
> Michal

NSCD should absolutely NOT be mandatory. There are many reasons not to 
run it (for example, maybe you actually want your identity lookups to be 
sane). NSCD provides unreliable (and occasionally unpredictable) 
behavior in identity caching. This is one of the reasons that the SSSD 
is being written to replace it. It is strongly advised NOT to run the 
SSSD and NSCD simultaneously (Things will still run, but NSCD will be 
acting as an additional cache, eliminating the predictability of the 
SSSD cache)

Stephen Gallagher
RHCE 804006346421761

Delivering value year after year.
Red Hat ranks #1 in value among software vendors.

More information about the devel mailing list