monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Test postgresql with a script


From: Luis
Subject: Test postgresql with a script
Date: Tue, 14 Feb 2012 12:22:09 +0100

Hi,

I'm monitoring postgresql with monit but the PGSQL protocol is pretty
limited because it only let you check the connection itself.
I would like to be able to send a query to postgresql to check if it's
working the way it should.
I have seen that there is a check program but only in 5.3+ versions
and it's an independent check.

I would like if there is any way to run a script as a check test (like
the host one, for example) that returns a exit status or another.
Something like this:

check process postgresql with pidfile /var/run/postgresql.pid
   start program = "/etc/init.d/postgresql start"
   stop program = "/etc/init.d/postgresql stop"
   if failed script <script_path> then restart

Or if anyone have any idea to check postgresql a bit deeper it would be great.

Thanks



reply via email to

[Prev in Thread] Current Thread [Next in Thread]