Xymon Mailing List Archive search

Bug: segfault in logfetch

1 message in this thread

list Jeremy Laidman · Thu, 25 Aug 2011 13:48:27 +1000 ·
Hi

I've been hit with a problem whereby a certain combination of log messages
and ignore/trigger settings cause logfetch to dump core during a memmove()
operation.  Same on both versions 4.3.4 and 4.3.3.  It only seems to happen
when I have an "ignore" clause (doesn't need to match anything) and a
trigger clause that matches a line in the logfile.

Backtrace from gdb:

#0  0x00002acb0153cdaa in _wordcopy_fwd_dest_aligned () from
/lib64/libc.so.6
#1  0x00002acb0153b1d0 in memmove () from /lib64/libc.so.6
#2  0x0000000000404030 in logdata (filename=0x5192d0 "./named.log",
logdef=0x519268) at logfetch.c:315
#3  0x00000000004042cb in main (argc=<value optimized out>, argv=<value
optimized out>) at logfetch.c:963

I've isolated the "logfetch.*" files from /tmp, and the 8 lines of log that
trigger the problem for me, so it's easy to reproduce the fault with these
files.  In some cases I can avoid the problem by reducing the logfile down
to less than the "maxbytes" setting in client-local.cfg, or increasing the
"maxbytes" value to larger than the logfile size.

Short of learning more C, I don't know what more I can do to find/fix the
problem.

Cheers
Jeremy