Hey, no big deal, I have received very quick help in the past. And yeah, I
was adding more info to have it "googled" for everybody else, in case it
helped.

For me, the most useful lesson: watch out your PHP extensions, because they
can cause this problem. (I'm learning Python/Django at the moment, and PHP
is quickly losing a lot of respect in my eyes... buy YMMV)
I think in my case, I ran updates on the server, and ClamAV was updated. The
php-clamav package has fallen out of date, and is unable to work with the
newest update of libclamav. It all happened at the same time as Cherokee
0.99.27, so I looked in that direction first. Seeing that the problem
happens with Lighttpd as well (and actually happens faster for some reason)
sent in the right direction, I hope!

I've learnt a lot a bout how FastCGI works in the last couple of days, let
me tell you :)

On Wed, Nov 18, 2009 at 10:38, Taher Shihadeh <[email protected]> wrote:

> Hi Urko!
> I guess no one has stepped up because, at least in my case, there was no
> experience using LibClamAV.
>
> Just talking about it in the mailing list *will* be useful for future
> reference, in case anyone encounters the same problem.
> So thanks for documenting the issue. :-)
>
> I hope you don't hit any more brick walls like this one, but if you do
> please come by for help.
>
> Regards,
> Taher
>
> Urko Masse wrote:
>
>> No replies, but I thought I should give an update:
>>
>> I tried decreasing the PHP_FCGI_MAX_REQUESTS to 499 (not even 500, just in
>> case), as mentioned in the Lighttpd documentation. The error 500 problem
>> happened again.
>>
>> I tried switching to Lighttpd, to see if it would work. The error 500
>> happened again. So I'm back to Cherokee, and looking at the PHP side of
>> things, because it's clear the problem is not on the web server side.
>> One more symptom that PHP is having issues: when I shut down Lighttpd, I
>> need to forcefully kill all the php5-cgi processes. Lighttpd is unable to
>> stop them, and they actually go into some sort of memory leak/race condition
>> during the shutdown, and CPU usage spikes to 100%, both processors, and
>> memory usage starts to increase steadily.
>>
>> I have removed the php-clamav extension (which was installed since who
>> knows when, but never used), and now the start and shutdown of Lighttpd
>> works fine, and the php5-cgi processes terminate normally, no need to kill
>> them.
>>
>> So I have switched back to Cherokee, without php-clamav now.
>> PHP_FCGI_MAX_REQUESTS is still at 499. I might increase it again in the
>> future if the issue has gone away, but I think the performance improvement
>> is not that noticeable.
>>
>> Thanks for reading this far :)
>>
>> On Tue, Nov 17, 2009 at 11:28, Urko Masse <[email protected] <mailto:
>> [email protected]>> wrote:
>>
>>    By the way, I have seen this in the documentation for Lighttpd:
>>
>>
>>        Why is my PHP application returning an error 500 from time to
>>        time?
>>
>>    This problem seems to stem from a little-known issue with PHP: PHP
>>    stops accepting new FastCGI connections after handling 500
>>    requests; unfortunately, there is a potential race condition
>>    during the PHP cleanup code in which PHP can be shutting down but
>>    still have the socket open, so lighty can send request number 501
>>    to PHP and have it "accepted", but then PHP appears to simply
>>    exit, causing a 500 return from lighty.
>>
>>
>>
>>
>>    On Tue, Nov 17, 2009 at 08:59, Urko Masse <[email protected]
>>    <mailto:[email protected]>> wrote:
>>
>>        Hello,
>>
>>        I'm having a strange issue. Last night Cherokee 0.99.27 went
>>        down, with internal server error 500.
>>
>>        When I check the Cherokee error log, I see a lot of lines with
>>        this error:
>>        LibClamAV Error: cl_load: engine == NULL
>>
>>        And also quite a few errors like:
>>        [16/11/2009 16:29:31.981] (warning) handler_file.c:173 -
>>        Unparseable time 'Sun, 33 Feb 3119 29:69:11 GMT'
>>
>>        I was running 0.99.23 before, because it was rock solid for me
>>        (and was too busy to touch something that works), and only
>>        recently upgraded to 0.99.27. Could it be related?
>>
>>        I include my cherokee.conf.
>>
>>        Please help!
>>
>>        PS: I'm going to look for the 0.99.23 deb file, just in case.
>>
>>
>>
>>
>
> --
> [email protected]
> http://unixwars.com/
>
>
_______________________________________________
Cherokee mailing list
[email protected]
http://lists.octality.com/listinfo/cherokee

Reply via email to