[Xymon] Core dump when using SCRIPT keyword

Mike Russo miker at readq.com
Wed Jan 8 17:13:17 CET 2014


Hi -
I've got a little problem wih Xymon 4.3.12 xymond_alert dumping core when trying to use the SCRIPT keyword in alerts.cfg.  We're trying to create a script that will contain some custom logic for whether to send alerts based on specific processes or not: we have a situation where we need to disable process checking for one particular process on certain hosts at a certain time of day but want the other process checks to continue and can't find any way of doing this with the standard arguments so we figured we'd have to pass along the checking to a custom script.

However when I try to set up the alert, I get a coredump, and the script does not run.  My alerts.cfg statement is:
HOST=%^rqstp.* SERVICE=procs
                SCRIPT /home/bb/RQTimedProcAlerts.sh rqit at readq.com DURATION>1m REPEAT=10 RECOVERED COLOR=red TIME=W:0801:1830

I have also tried to eliminate some of those other keywords and gone to the simple:
                SCRIPT /home/bb/RQTimedProcAlerts.sh rqit at readq.com COLOR=red

But I still experience the coredump. Here is a backtrace:

[bb at bongo server]$ gdb bin/xymond_alert core.19031
GNU gdb (GDB) CentOS (7.0.1-45.el5.centos)
Copyright (C) 2009 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "i386-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from /home/bb/server/bin/xymond_alert...done.
[New Thread 19031]

warning: .dynamic section for "/lib/libpthread.so.0" is not at the expected address

warning: difference appears to be caused by prelink, adjusting expectations

warning: .dynamic section for "/usr/lib/libgssapi_krb5.so.2" is not at the expected address

warning: difference appears to be caused by prelink, adjusting expectations

warning: .dynamic section for "/lib/libdl.so.2" is not at the expected address

warning: difference appears to be caused by prelink, adjusting expectations
Reading symbols from /lib/librt.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/librt.so.1
Reading symbols from /lib/libssl.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libssl.so.6
Reading symbols from /lib/libcrypto.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libcrypto.so.6
Reading symbols from /lib/libpcre.so.0...(no debugging symbols found)...done.
Loaded symbols for /lib/libpcre.so.0
Reading symbols from /lib/libc.so.6...(no debugging symbols found)...done.
Loaded symbols for /lib/libc.so.6
Reading symbols from /lib/libpthread.so.0...(no debugging symbols found)...done.
[Thread debugging using libthread_db enabled]
Loaded symbols for /lib/libpthread.so.0
Reading symbols from /lib/ld-linux.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/ld-linux.so.2
Reading symbols from /usr/lib/libgssapi_krb5.so.2...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libgssapi_krb5.so.2
Reading symbols from /usr/lib/libkrb5.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5.so.3
Reading symbols from /lib/libcom_err.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libcom_err.so.2
Reading symbols from /usr/lib/libk5crypto.so.3...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libk5crypto.so.3
Reading symbols from /lib/libresolv.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libresolv.so.2
Reading symbols from /lib/libdl.so.2...(no debugging symbols found)...done.
Loaded symbols for /lib/libdl.so.2
Reading symbols from /lib/libz.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libz.so.1
Reading symbols from /usr/lib/libkrb5support.so.0...(no debugging symbols found)...done.
Loaded symbols for /usr/lib/libkrb5support.so.0
Reading symbols from /lib/libkeyutils.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libkeyutils.so.1
Reading symbols from /lib/libselinux.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libselinux.so.1
Reading symbols from /lib/libsepol.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libsepol.so.1
Reading symbols from /lib/libgcc_s.so.1...(no debugging symbols found)...done.
Loaded symbols for /lib/libgcc_s.so.1
Core was generated by `xymond_alert --checkpoint-file=/home/bb/server/tmp/alert.chk --checkpoint-inter'.
Program terminated with signal 6, Aborted.
#0  0x00dba402 in __kernel_vsyscall ()
(gdb) bt
#0  0x00dba402 in __kernel_vsyscall ()
#1  0x00605e30 in raise () from /lib/libc.so.6
#2  0x00607741 in abort () from /lib/libc.so.6
#3  0x0063e8cb in __libc_message () from /lib/libc.so.6
#4  0x00648f11 in _int_realloc () from /lib/libc.so.6
#5  0x0064aea6 in realloc () from /lib/libc.so.6
#6  0x006088e5 in __add_to_environ () from /lib/libc.so.6
#7  0x00608657 in putenv () from /lib/libc.so.6
#8  0x0804eb49 in send_alert (alert=0x9ab9d68, logfd=0x9ab8250) at do_alert.c:627
#9  0x0804b62d in main (argc=Cannot access memory at address 0x4a57
) at xymond_alert.c:890
(gdb)


--
Michael Russo, ReadQ Systems Inc.
1 Whitehall Street, 16th Floor, NY NY 10004

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20140108/b402e71c/attachment.html>


More information about the Xymon mailing list