Crash in gethostbyname() on congruent usage

2012-12-12 Thread Erik
Hi, [Please keep me on CC:, I'm not subscribed] I'm working with current uClibc on a system with 2 CPU cores and had problems with gethostbyname() function if several threads will use it together. The congruent usage of gethostbyname() (uClibc-9.32.1) by at least two threads can cause a crash

Re: iozone compilation failure with uclibc due to aio

2012-12-12 Thread Carmelo AMOROSO
On 10/12/2012 18.27, Rich Felker wrote: On Mon, Dec 10, 2012 at 05:43:54PM +0530, Madhu koriginja wrote: Hi All, I am facing compilation issue with the iozone compilation failure with uclibc library. I am using the uclibc 0.9.32 version, gcc 4.5 linaro toolchain. The same code is compiling

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Rich Felker
On Wed, Dec 12, 2012 at 01:17:18PM +, Erik wrote: Hi, [Please keep me on CC:, I'm not subscribed] I'm working with current uClibc on a system with 2 CPU cores and had problems with gethostbyname() function if several threads will use it together. The congruent usage of

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Laurent Bercot
On Wed, Dec 12, 2012 at 09:55:43AM -0500, Rich Felker wrote: Really, you should be using the modern interface, getaddrinfo, and forgetting you ever heard of gethostbyname, since we're almost in 2013 and gethostbyname, by design, cannot support IPv6. Obligatory rant against getaddrinfo() :

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Rich Felker
On Wed, Dec 12, 2012 at 04:46:11PM +0100, Laurent Bercot wrote: On Wed, Dec 12, 2012 at 09:55:43AM -0500, Rich Felker wrote: Really, you should be using the modern interface, getaddrinfo, and forgetting you ever heard of gethostbyname, since we're almost in 2013 and gethostbyname, by

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread u-uclibc-cmdy
Hello Rich, On Wed, Dec 12, 2012 at 12:05:55PM -0500, Rich Felker wrote: uClibc. If you want to lookup hostnames, you use getaddrinfo. If that's doing something other than straight DNS, that's because the administrator has a damn good reason to want hostname lookups to be performed in some

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Rich Felker
On Wed, Dec 12, 2012 at 07:11:55PM +, u-uclibc-c...@aetey.se wrote: Hello Rich, On Wed, Dec 12, 2012 at 12:05:55PM -0500, Rich Felker wrote: uClibc. If you want to lookup hostnames, you use getaddrinfo. If that's doing something other than straight DNS, that's because the

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread u-uclibc-cmdy
On Wed, Dec 12, 2012 at 02:30:40PM -0500, Rich Felker wrote: Note that your argument that it should not be possible to replace the global DNS namespace with a local hack is a _policy_ argument, not a Kind of. In short, getaddrinfo should (per sane policy) be DNS, plus possibly some set of

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Laurent Bercot
The thread you referenced is all silly; it's a rant about an implementation detail (NSS) of glibc that does not even apply to uClibc. If you want to lookup hostnames, you use getaddrinfo. Whether or not NSS is a glibc implementation detail, getaddrinfo() was designed to accommodate NSS, and

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread Rich Felker
On Thu, Dec 13, 2012 at 02:03:31AM +0100, Laurent Bercot wrote: The thread you referenced is all silly; it's a rant about an implementation detail (NSS) of glibc that does not even apply to uClibc. If you want to lookup hostnames, you use getaddrinfo. Whether or not NSS is a glibc

Re: Crash in gethostbyname() on congruent usage

2012-12-12 Thread u-uclibc-cmdy
On Wed, Dec 12, 2012 at 09:36:53PM -0500, Rich Felker wrote: is how to support alternate backends for other non-DNS things NSS provides -- mainly the user database -- without ugly hacks like putting them all in the libc. The eventual solution will probably be some sort of proxying daemon that