- changed status to resolved
Monit 5.25.0 crashes in Util_resetInfo() after checked process stopped.
Issue #688
resolved
We upgraded from 5.20 to 5.25, no changes to monitrc. Monit now stops unexpectedly with SIGSEGV or SIGABRT when a checked process stops and has removed it's PID-file.
strace last lines:
getpgid(7821) = 7820
getpgid(7826) = -1 ESRCH (No such process)
stat("/home/user/run/program.pid", 0x...) = -1 ENOENT (No such file or directory)
--- SIGSEGV {si_signo=SIGSEGV, si_code=SEGV_MAPERR, si_addr=0} ---
gdb stack:
Program received signal SIGABRT, Aborted.
0x00007f1439a9c1f7 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
56 return INLINE_SYSCALL (tgkill, 3, pid, selftid, sig);
(gdb) where
#0 0x00007f1439a9c1f7 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56
#1 0x00007f1439a9d8e8 in __GI_abort () at abort.c:90
#2 0x00007f1439adbf47 in __libc_message (do_abort=do_abort@entry=2, fmt=fmt@entry=0x7f1439be8608 "*** Error in `%s': %s: 0x%s ***\n") at ../sysdeps/unix/sysv/linux/libc_fatal.c:196
#3 0x00007f1439ae1b54 in malloc_printerr (action=<optimized out>, str=0x7f1439be8630 "munmap_chunk(): invalid pointer", ptr=<optimized out>, ar_ptr=<optimized out>) at malloc.c:5023
#4 0x00000000004276fe in Util_resetInfo ()
#5 0x0000000000443759 in ProcessTree_findProcess ()
#6 0x000000000042f3b2 in check_process ()
#7 0x000000000042caaa in validate ()
#8 0x00000000004138ea in do_action ()
#9 0x000000000041464f in main ()
Might be related to recently added line src/util.c:1780 of release-5-25-0.
Comments (1)
-
repo owner - Log in to comment
Fixed: Issue
#688: Linux: Monit may crash if the monitored process stopped (5.25.0 regression).→ <<cset 958deea6fdc9>>