From owner-freebsd-hackers@FreeBSD.ORG Wed Jul 13 12:47:02 2005 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AEB1316A41C for ; Wed, 13 Jul 2005 12:47:02 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from postfix4-2.free.fr (postfix4-2.free.fr [213.228.0.176]) by mx1.FreeBSD.org (Postfix) with ESMTP id 539AD43D48 for ; Wed, 13 Jul 2005 12:47:02 +0000 (GMT) (envelope-from tataz@tataz.chchile.org) Received: from tatooine.tataz.chchile.org (vol75-8-82-233-239-98.fbx.proxad.net [82.233.239.98]) by postfix4-2.free.fr (Postfix) with ESMTP id 36423322018; Wed, 13 Jul 2005 14:47:00 +0200 (CEST) Received: by tatooine.tataz.chchile.org (Postfix, from userid 1000) id 33A5A405B; Wed, 13 Jul 2005 14:46:58 +0200 (CEST) Date: Wed, 13 Jul 2005 14:46:58 +0200 From: Jeremie Le Hen To: Christophe Yayon Message-ID: <20050713124658.GU39292@obiwan.tataz.chchile.org> References: <61087.192.168.42.2.1121196788.squirrel@webmail.nbux.com> <20050713095059.GS39292@obiwan.tataz.chchile.org> <44776.194.51.215.62.1121257035.squirrel@webmail.nbux.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <44776.194.51.215.62.1121257035.squirrel@webmail.nbux.com> User-Agent: Mutt/1.5.9i Cc: freebsd-hackers@freebsd.org Subject: Re: nagios and pthreads X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Jul 2005 12:47:02 -0000 Christophe, > Yes but if i understand, there is a bug in libc_r on FreeBSD ? libc_r indeed has some kind of bug, I don't know. Anyhow, you are using RELENG_5, so you should be using native threads with either libpthread (libkse, M:N) or libthr (1:1). I don't know what Nagios does just after fork(2), it would be worth to check. It appears that fork(2)ing without exec(2)ing or _exit(2)ing in a pthreaded program is not a "valid" behaviour, regarding to SUSv3 [1]. I don't want to avoid admitting there is a problem in FreeBSD threading library, I don't know how other OSes handle this, but Nagios folks should really avoid doing what is explicitely dissuaded in SUSv3. For now, it doesn't resolve your problem unfortunately. [1] http://www.opengroup.org/onlinepubs/009695399/functions/pthread_atfork.html (look at the "RATIONALE" section) -- Jeremie Le Hen < jeremie at le-hen dot org >< ttz at chchile dot org >