[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [monit] Aborting monit on failure
From: |
Stephan-Frank Henry |
Subject: |
Re: [monit] Aborting monit on failure |
Date: |
Fri, 07 Aug 2009 10:58:16 +0200 |
> Stephan-Frank Henry wrote:
> > I have a requirement to have a monitoring system that will monitor a
> > file and a remote server (+ more later maybe) and if one of both
> > fails, the system should execute a scrip and then stop dead (i.e.
> > monit stop).
>
> Aleksander Kamenik wrote:
> Hi,
>
> It's "monit quit", but may I ask why do you want monit to kill itself
> instead of say "monit stop all && monit unmonitor all"? I just can't
> imagine why the kill is necessary.
>
> Regards,
Hi,
First off, thanks to all for the replies.
@Kill:
to be honest I just wanted to get it working and thought this would do.
After the failure case, I really do not need monit running any more so I
thought I would just kill it.
Plus, and currently the actual reason, as mentioned, I would also not see the
scripts being executed if it was *not* killed.
If there is a cleaner way, perfect. I just need those scripts executed.
Here is my current conf:
>
set daemon 15
set logfile syslog facility log_daemon
check file slony_log with path /var/log/slony1/slony1.log
if match "FATAL" then exec "/home/frank/monit/fail_action.sh"
check host db_server_01 with address db_server_01
if failed host db_server_01 port 5432 protocol pgsql then exec
"/home/frank/monit/fail_action.sh"
depends on slony_log
<
The fail_action.sh is basically just a wrapper around a group of other scripts
I want to execute at runtime:
Stop slony (PostgreSQL replication system), failover the database and then stop
monit or at least make sure it does not monitor anything anymore. I would not
like for the master db to come back up and cause my system to go crazy on me. :)
regards,
Frank
--
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3 -
sicherer, schneller und einfacher! http://portal.gmx.net/de/go/atbrowser
- [monit] Aborting monit on failure, Stephan-Frank Henry, 2009/08/06
- Re: [monit] Aborting monit on failure, Martin Pala, 2009/08/06
- Re: [monit] Aborting monit on failure, Aleksander Kamenik, 2009/08/07
- Re: [monit] Aborting monit on failure,
Stephan-Frank Henry <=
- Re: [monit] Aborting monit on failure, Eric Pailleau, 2009/08/07
- Re: [monit] Aborting monit on failure, Stephan-Frank Henry, 2009/08/07
- Re: [monit] Aborting monit on failure, Eric Pailleau, 2009/08/07
- Re: [monit] Aborting monit on failure, Stephan-Frank Henry, 2009/08/07
- Re: [monit] Aborting monit on failure, Eric Pailleau, 2009/08/07
- Re: [monit] Aborting monit on failure, Stephan-Frank Henry, 2009/08/07
- Re: [monit] Aborting monit on failure, Eric Pailleau, 2009/08/07
- Re: [monit] Aborting monit on failure, Stephan-Frank Henry, 2009/08/10
Re: [monit] Aborting monit on failure, Eric Pailleau, 2009/08/07