httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Boyle Owen" <Owen.Bo...@six-group.com>
Subject RE: [users@httpd] How to detect a non-graceful restart of Apache
Date Fri, 19 Jun 2009 07:43:50 GMT
> -----Original Message-----
> From: SAILESH KRISHNAMURTI, BLOOMBERG/ 731 LEXIN 
> [mailto:skrishnamur1@bloomberg.net] 
> Sent: Thursday, June 18, 2009 3:42 PM
> To: USERS@httpd.apache.org
> Subject: [users@httpd] How to detect a non-graceful restart of Apache
> 
> Hi, I have a requirement wherin application owners would like 
> to be notified if apache is restarted non-gracefully, since 
> there might be impact to user sessions etc... Is there any 
> way to detect and report this, hopefully without compiling 
> additional modules? thanks

The simplest way is probably to monitor the error_log (eg, with a
perl-script running under cron). If there is a stop; you get a SIGTERM
in the log. For a restart; there is a SIGHUP. For a graceful; no
signals, just a message.

Alternatively, if you have mod_server_status, you could poll it. The
server uptime is reset to zero if there is a stop/start or restart, but
keeps ticking if there is a graceful.

Rgds,
Owen Boyle
Disclaimer: Any disclaimer attached to this message may be ignored. 

> 
 
This message is for the named person's use only. It may contain confidential, proprietary
or legally privileged information. If you receive this message in error, please notify the
sender urgently and then immediately delete the message and any copies of it from your system.
Please also immediately destroy any hardcopies of the message. 
The sender's company reserves the right to monitor all e-mail communications through their
networks.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message