Check file does not work some times.

Issue #866 new
nyash created an issue

Hello,

We have check log file of monit for zombie processes:

//For all processes that demand a board restart, do a board restart in case they create zombies
check file superd with path /var/log/superd.log
   mode manual
   if match "'procces_name_1' process with pid [0-9]{1,8} is a zombie" then \
exec "/bin/bash -c '/usr/libexec/monit-restart.sh procces_name_1'"

   if match "'procces_name_2' process with pid [0-9]{1,8} is a zombie" then \
exec "/bin/bash -c '/usr/libexec/monit-restart.sh procces_name_2'"

We have test case where we do OOM for procces_name_1 , have seen log “'procces_name_1' process with pid 4532 is a zombie“ but no actions happens.

Do you have something similar issue?

Best regards, Alexey.

Comments (3)

  1. nyash reporter

    I got what happening. I checked this case for monit 5.21.0 and got same result.

    Syslog write some binary data to checked file (/var/log/superd.log). Monit in static State_Type _checkMatch(Service_T s) can’t go throw this binary data and does not check file later this binary data.

  2. Log in to comment