monit-general
[Top][All Lists]
Advanced

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

Re: a) HTTP-Port & quitting, b) monit ran amok on my apache


From: Jan-Henrik Haukeland
Subject: Re: a) HTTP-Port & quitting, b) monit ran amok on my apache
Date: 01 Jul 2002 23:23:41 +0200
User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Civil Service)

Whops! This was new.

Christian Hopp <address@hidden> writes:

> Problem a)
> ----------
> 
> Mostly when monit is quitted (SIGQUIT, SIGTERM and SIGKILL) there
> happens something really strange... monit is quited but many of my
> servers are reported to listen to monit's HTTP port (here 2812).
> Thus, monit can't restart with HTTP support, because the port is
> already occupied

I suspect part of this to come from the socket linger code. Funny
enough I removed this yesterday since it's not something we use and
monit http will manage without. There is a new beta out on:

 http://www.tildeslash.com/monit/beta/

(The email date headers is also fixed in this release)

Can you check out this relase and see if it helps.

> sh        12100     root ... TCP *:2812 (LISTEN)
> custom_lo 12103     root ... TCP *:2812 (LISTEN)
> httpd     12104    httpd ... TCP *:2812 (LISTEN)
> (...)
> httpd     12180    httpd ... TCP *:2812 (LISTEN)
> 
> I have never seen a sh listening on a port.

This could be due to the fork done by monit before it starts a new
program. But one thing first. Check out the beta release first. And
what does: 'netstat -a -t tcp' says?


> Problem b)
> ----------
> 
> Furthermore monit ran amok on my apache this Sunday.  Apache is
> stopped (with 'monit stop apache') and started (with 'monit start
> apache') in the night for minute (logfiles and so on).  After the run
> on Sunday morning monit restarted my apache because apache returned
> 503.  Look at this syslog extract.
> 
> Jun 30 09:20:56 iei1 monit[509]:
>  HTTP error: HTTP/1.1 503 Service Unavailable
> Jun 30 09:20:56 iei1 monit[509]:
>  'apache', test with protocol [HTTP] failed at localhost:80.
> Jun 30 09:20:56 iei1 monit[509]:
>  Trying to restart 'apache'
> Jun 30 09:20:56 iei1 monit[509]:
>  Stop: (apache) /etc/init.d/apache stop
> Jun 30 09:21:06 iei1 monit[509]:
>  Start: (apache) /etc/init.d/apache start
> Jun 30 09:23:10 iei1 monit[509]:
>  HTTP error: HTTP/1.1 503 Service Unavailable
> Jun 30 09:23:10 iei1 monit[509]:
>  'apache', test with protocol [HTTP] failed at localhost:80.
> Jun 30 09:23:10 iei1 monit[509]:
>  Trying to restart 'apache'
> Jun 30 09:23:10 iei1 monit[509]:
>  Stop: (apache) /etc/init.d/apache stop
> Jun 30 09:23:20 iei1 monit[509]:
>  Start: (apache) /etc/init.d/apache start
> 
> The 503 (Service Unavailable) was also reported on access_log.

>From the HTTP/1.1 spec:

503 Service Unavailable - The server is currently unable to handle the
request due to a temporary overloading or maintenance of the server.

What is the poll-cycle time, or better send us the monitrc file you
are using. It could be that the port check is to soon and apache is in
some initialization faze.

> But the rest of apache worked fine (normal accesses have taken place).
> In the morning of Monday apache was restarted on plan and monit
> behaved normally again.  Might it be connected to Problem a)?

Probably not.

-- 
Jan-Henrik Haukeland



reply via email to

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