|
Understood. And stuff like this is really, really,
hard. You're dealing with edge cases and interpretation of fuzzy grey
areas in standards... often things that aren't actually even understood to
be interpretations!
For example, POSIX threads is POSIX threads, right?
Well, no. There are behaviors we have grown to expect in how threads work
that turn out to be artifacts of the use of separate OS processes and that are
not required by POSIX. Move to a true light-weight (user land) threads
situation like FreeBSD and lots of things go 'wrong'. The only reason ntop
does it right is a lot of hard work done around the time we realized that Red
Hat's NPTL did things 'differently'.
If you have the
choice, stick with Linux. FreeBSD works, but it's
rougher. Signal delivery is another area where you get hung up -
POSIX doesn't require that a signal be delivered to a particular listener, just
somebody listening for that signal. So if you have two users generating
long html reports, both set the alarm() call in their thread. If it's
separate OS processes, each has their own signal handler and receives their own
alarm. W/ user land threads, there is a thread handler that receives the
alarm() and 'decides' which handler to invoke. So you could get the
alarm() for the other user! Perfectly legal, but not what you
expect...
This is especially true because we use the
'prohibited' thread+fork() coding style. Forget that almost every other
multi-threaded project does it (there are some serious performance gains in
using fork() with it's copy-on-write memory snapshot, vs. safely copying the
whole data structure - which requires shared memory (ug) and holding locks for
long periods).
-----Burton
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Shane Mullins Sent: Saturday, December 04, 2004 10:31 PM To: [EMAIL PROTECTED] Subject: Re: [Ntop] OpenBSD 3.6 and ntop 3.0 Thanks Burton,
I will have to stay with a
supported platform. I wish I was a strong programmer, but I am very far
from it. If I was a strong programmer I would pitch in and
help.
Thanks so much,
Shane
PS OpenBSD 3.6 produced the same
error.
|
_______________________________________________ Ntop mailing list [EMAIL PROTECTED] http://listgateway.unipi.it/mailman/listinfo/ntop
