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

Re: apache-ssl restart fails after monthly logrotate



On Fri, Apr 11, 2003 at 10:26:57AM -0600, David Wilk wrote:
Hi, 

I seen similar problem on RedHats - logs are rotated daily there by
default. Apache with ssl enabled was failing to restart after log rotation
after 3 month of use, but in my case I had errors like "can't load certificate 
file" or something like that in my errorlog (though I didn't touch any file 
in the dir with certs on those boxen for half of a year).

My investigntation shown that it's some kind of leak in apache. When log
rotation is finished, SIGHUP is sent to parent apache, and parent seems to 
unload and then load all modules - and something leaks during this process. 
To simulate it I wrote a script that sent apache SIGHUPs in the loop with
2 seconds delay, and on 100th (3*33! - that's why 3 month) signal apache 
failed to restart..

Solution is to rewrite apache log rotation scripts to detect whether apache
failed to restart, and start it if it did.

-- 
 Best regards,
  -Vlad

> Howdy folks,
> 
> I've been admining debian servers for a few years now and this problem
> is a new one on me.  I have the standard apache-ssl setup with logrotate
> handling standard logrotation of about 115 virtual hosts in
> /var/log/httpd/.  for the first 3 months or so everything went fine at
> the monthly log rotation, however for the last 2 months apache-ssl has
> failed to restart after logrotation.
> 
> The last time this happened, I found the apache parent gone, with
> several children straggling around.  I couldn't just issue an
> /etc/init.d/apache-ssl start, but had to manually kill the children
> first.  There is simply nothing in the logs (well, nothing in
> /var/log/apache-ssl logs and the most active virtual host, but I did not
> check all virtual host logs)
> 
> has anyone seen this before?
> 
> oh, system is Debian/Woody on a PIII/1.2G 2G-RAM with plenty of disk
> space.
> 
> any ideas would be greatly appreciated!
> 
> thanks,
> Dave
> -- 
> *******************************
> David Wilk
> System Administrator
> Community Internet Access, Inc.
> admin@cia-g.com
> 
> 
> -- 
> To UNSUBSCRIBE, email to debian-isp-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Reply to: