help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: DNS problem


From: Xavier Maillard
Subject: Re: DNS problem
Date: Wed, 27 Sep 2006 01:15:39 +0200
User-agent: VM /GNU Emacs 22.0.50.1 on GNU/Linux

  On Tuesday, 26 September 2006, Barry Margolin wrote:
> In article <mailman.7391.1159211762.9609.help-gnu-emacs@gnu.org>,
>  Xavier Maillard <zedek@gnu.org> wrote:
> 
> >   On Saturday, 23 September 2006, William Xu wrote:
> > > Hi there, 
> > > 
> > > If DNS doesn't work before starting emacs, and after startup, i fix DNS
> > > problem. Then i find emacs still has DNS problem, e.g., it couldn't
> > > connect irc (using erc) or newsgroups by hostname. I restarted emacs, it
> > > works. Is this normal?
> > 
> > That's a known "issue" (not to say bug) with the libc resolver. I
> 
> By default, the resolver only reads /etc/resolv.conf the first time it's 
> used in a process, and it caches the settings from then on.  So any 
> long-lived processes always need to be restarted if you change this file 
> and you want them to pick up the changes.

Before patching glibc (which is a non-trivial and may have side
effects on general glibc behaviour), you can "force" clients to
ack on resolv.conf changes by using the nscd command.

Ex: nscd -i hosts

This could be put in the script responsible to write your
/etc/resolv.conf for example. Or you can have a task watching for
resolv.conf timestamp and automatically call nscd when it changes.

Anyway, I opened a bug on bugs.gentoo.org[1] with a patch against
glibc-2.4. Note that libc-alpha do not want to do anything with
this and says to use nscd instead of this.


Footnotes: 
[1]  http://bugs.gentoo.org/show_bug.cgi?id=149124

-- 


CU Xavier




reply via email to

[Prev in Thread] Current Thread [Next in Thread]