FreeBSD thread issues

Andreas Ericsson ae at op5.se
Fri Aug 19 21:45:19 CEST 2005


Christophe Yayon wrote:
> Andreas,
> 
> in others words, it appears that Nagios is right and FreeBSD do not accept
> the 'fork method' choice of Nagios...

Most likely, yes. It does, however, appear that the spec should either 
be fixed so that it is absolutely certain how a fork()'ing application 
should behave, and they should definitely leave suggestions out of it, 
since those have a way of being misinterpreted as recommendations.

Perhaps the threads library shouldn't bother with mutexes and just leave 
it to the application coder to make sure a fork()'ed thread never runs 
into a deadlock. That seems by far the most sensible (and for all 
parties easiest) approach.

> The solution for our problem seems to have a specific Nagios patch for
> FreeBSD...
> Perhaps Nagios committer could do something, i will contact him ...
> 

Maybe. It's entirely possible that it will be easier to migrate to a 
one-thread-per-check solution rather than the current approach. It will 
certainly shave a fair few cycles off the running of checks.

-- 
Andreas Ericsson                   andreas.ericsson at op5.se
OP5 AB                             www.op5.se
Lead Developer


-------------------------------------------------------
SF.Net email is Sponsored by the Better Software Conference & EXPO
September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf




More information about the Developers mailing list