Subject: Problems trying to debug pkgsrc/mail/milter-greylist
To: NetBSD port-sparc64 mailing list <port-sparc64@netbsd.org>
From: Chris Ross <cross+netbsd@distal.com>
List: port-sparc64
Date: 11/21/2007 10:17:38
Hi there. I have a sparc64 running 4.0_RC3, and I built pkgsrc/
mail/milter-greylist. I notice that it sometimes just dies. I
upgraded the pkgsrc tree to the current release (4.0, vs the 3.0
that's in pkgsrc currently), but it seems to fail in about the same way.
I was seeing multiple problems. Right now, however, I'm wondering
if somethings wrong somewhere related to threading. All of the
errors seem to have a backtrace that ends:
#7 0x00000000405137cc in pthread_join () from /usr/lib/libpthread.so.0
#8 0x0000000040ba7fc0 in _lwp_makecontext () from /usr/lib/libc.so.12
#9 0x0000000040ba7fc0 in _lwp_makecontext () from /usr/lib/libc.so.12
Previous frame identical to this frame (corrupt stack?)
(gdb)
The exact cause for the crash varies, but. I'm not an expert on
using gdb to debug threaded programs by any means, but was wondering:
1) The resolver in NetBSD 4 is BIND 9, so definitely thread-safe,
right?
2) Are gdb or libpthreads on sparc64 known to have any problems?
3) Anyone have any good pointers to "how to debug a threaded
program with gdb" ?
milter-greylist doesn't have many threads running ever. It just
spawns off new threads for synchronization (which I'm not using), and
dumping of data. One for reading the config file too, I think, but I
suspect that's not happening repeatedly.
Anyway. Thanks...
- Chris