Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Cherokee: users

Strange LibClamAV error, and Error 500

 

 

Cherokee users RSS feed   Index | Next | Previous | View Threaded


urko.masse at gmail

Nov 16, 2009, 5:59 PM

Post #1 of 5 (510 views)
Permalink
Strange LibClamAV error, and Error 500

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.
Attachments: cherokee.conf (15.1 KB)


urko.masse at gmail

Nov 16, 2009, 8:28 PM

Post #2 of 5 (494 views)
Permalink
Re: Strange LibClamAV error, and Error 500 [In reply to]

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 <urko.masse [at] gmail> 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.
>


urko.masse at gmail

Nov 17, 2009, 5:25 PM

Post #3 of 5 (494 views)
Permalink
Re: Strange LibClamAV error, and Error 500 [In reply to]

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 <urko.masse [at] gmail> 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 <urko.masse [at] gmail> 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.
>>
>
>


taher at unixwars

Nov 17, 2009, 7:38 PM

Post #4 of 5 (490 views)
Permalink
Re: Strange LibClamAV error, and Error 500 [In reply to]

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 <urko.masse [at] gmail
> <mailto:urko.masse [at] gmail>> 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 <urko.masse [at] gmail
> <mailto:urko.masse [at] gmail>> 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.
>
>
>


--
taher [at] unixwars
http://unixwars.com/

_______________________________________________
Cherokee mailing list
Cherokee [at] lists
http://lists.octality.com/listinfo/cherokee


urko.masse at gmail

Nov 17, 2009, 8:29 PM

Post #5 of 5 (487 views)
Permalink
Re: Strange LibClamAV error, and Error 500 [In reply to]

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 <taher [at] unixwars> 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 <urko.masse [at] gmail <mailto:
>> urko.masse [at] gmail>> 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 <urko.masse [at] gmail
>> <mailto:urko.masse [at] gmail>> 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.
>>
>>
>>
>>
>
> --
> taher [at] unixwars
> http://unixwars.com/
>
>

Cherokee users RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.