monit-general
[Top][All Lists]
Advanced

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

Re: Execution failed ?


From: Martin Pala
Subject: Re: Execution failed ?
Date: Wed, 13 Oct 2004 21:49:15 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.3) Gecko/20041007 Debian/1.7.3-5

This is strange - i tried to replicate the problem but it works for me without problems. It is possible that the /usr/local/pgsql/data/postmaster.pid cointained pid of nonexisting process (some previous postgres instance which was stopped and the pidfile was not updated).

You can safely ignore smtp related messages - it is not related to this problem (exactly as you noted - it is correct and is caused by unavailable smtp server ;)

If you can recreate the problem, please try (maybe it could be good to run monit in debug mode):

1.) check the content of monitored postmaster.pid vs. actual process table (exist/nonexist?)

2.) unmonitor postgres in monit

3.) restart postgres or whatever ...

4.) enable postgres monitoring

5.) check the content of monitored postmaster.pid vs. actual process table (exist/nonexist?)

Cheers,
Martin


Andreas Rust wrote:

Hi,

I just migrated a postgresql DB to a new server and wonder about something ...

Server is running Monit 4.4-beta5 and before I started to mess with postgres I hit the disable monitoring button on the webinterface. When I was done with my testing and everything, I hit the enable monitoring button and got the message "execution failed" in shiny red letters.

Ofcourse postgres was up and running when I re-enabled monitoring, so I wonder where this comes from.

Here some relevant stuff:

config part:

check process postgres with pidfile /usr/local/pgsql/data/postmaster.pid
    start program = "/etc/init.d/postgresql start"
    stop program = "/etc/init.d/postgresql stop"
    group server
    if failed host 127.0.0.1 port 5432 then restart
    if cpu > 70% for 5 cycles then restart
    if 7 restarts within 10 cycles then timeout

(is this more or less ok ? I think so ... )

And here the excerpt from the log:
(ignore the mailserver stuff ... no mailserver available there currently :) )


[CEST Oct 12 18:36:17] 'postgres' process is not running
[CEST Oct 12 18:36:17] Cannot open a connection to the mailserver 'localhost:25' -- Transport endpoint is not connected
[CEST Oct 12 18:36:17] No mail servers are available, aborting alert
[CEST Oct 12 18:36:17] 'postgres' trying to restart
[CEST Oct 12 18:36:17] 'postgres' start: /etc/init.d/postgresql
[CEST Oct 12 18:37:17] 'postgres' failed to start

---- doesnt really matter until here ...

[CEST Oct 12 18:37:17] Cannot open a connection to the mailserver 'localhost:25' -- Transport endpoint is not connected
[CEST Oct 12 18:37:17] No mail servers are available, aborting alert

Somewhere around this time (18:36) I disabled the monitoring --- nothing dramatic or suspicious until here.

[CEST Oct 12 20:20:46] 'postgres' process is running with pid 21064
[CEST Oct 12 20:20:46] Cannot open a connection to the mailserver 'localhost:25' -- Transport endpoint is not connected
[CEST Oct 12 20:20:46] No mail servers are available, aborting alert

I re-enabled the monitoring at 20:20.
Monit sees the running process ... it is not supposed to notify me on the enabling of monitoring, or ? After initializing it comes up with the red "execution failed" message --- which MAY come from the mailserver ?

[CEST Oct 12 20:27:31] 'postgres' stop: /etc/init.d/postgresql
[CEST Oct 12 20:27:34] 'postgres' stopped
[CEST Oct 12 20:27:34] Cannot open a connection to the mailserver 'localhost:25' -- Transport endpoint is not connected
[CEST Oct 12 20:27:34] No mail servers are available, aborting alert
[CEST Oct 12 20:27:37] 'postgres' start: /etc/init.d/postgresql

This stop/start I made over the webinterface aswell and afterwards all was fine ...

... so, whats the message the execution failed shall give me ?
postgres was up and running fine, the message however irritates me and I wonder if it makes sense at all in this case.

l8r


    Andreas Rust     -   webnova GmbH
    address@hidden  -   www.webnova.de
    Tel:  +49 (0)700 - 20 30 7000
    Fax:  +49 (0)700 - 20 30 8000
+:----------------------------------------------------------:+
         www.Synergien-Nutzen.de
         Gemeinsam sind wir stark...


------------------------------------------------------------------------

--
To unsubscribe:
http://lists.nongnu.org/mailman/listinfo/monit-general





reply via email to

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