This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: getaddrinfo() fails to use latest DNS address - v2.27


* Tarun Tej K.:

> As per the strace, when problem occurs even stat64 call is not taking
> place. (That means __resolv_conf_get_current is not being called?)

Yes.

> In any case, shouldn't stat64() happen everytime the getaddrinfo() is
> called?

Indeed.

> Can you please suggest any way to investigate why even stat64 was not
> happening and getaddrinfo is returning with EAGAIN forever until the
> process is restarted?

It could mean that reloading is disabled.  There are a few possible
causes:

* The noreload option is specified in /etc/resolv.conf.

* The application sets RES_NORELOAD in res.options directly.

* The application updates other data in _res, so that it no longer
  matches the previously read configuration.

The last part could also happen due to completely different bugs,
e.g. after heap corruption.

Regarding bugs, I'm not aware of any.  In general, reloading of the
configuration is inhibited for a thread if it has an attached context.
Maybe there is a bug in this area.  Do you have a coredump?  It should
be visible in the current variable in resolv/resolv_context.c.

> Also could you suggest any other tool other than strace to see the
> call trace of libc runtime?

Systemtap might be an option.

Thanks,
Florian


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]