Server Error 500 under heavy load

Random stuff about serendipity. Discussion, Questions, Paraphernalia.
onli
Regular
Posts: 2825
Joined: Tue Sep 09, 2008 10:04 pm
Contact:

Re: Server Error 500 under heavy load

Post by onli »

If the error is really under heavy load, it is highly unlikely that a simple error in an update of a plugin may cause this. Did you already check the error.log of apache or any other logs? The exact cause of the 500 should be detectable.

Using cloudflare isn't bad advice as well.

Apart from that, i fear that experience with high-traffic-setups of s9y is very limited.
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

Thanks for that! Unfortunately I do not have access to the logs. I have read a lot of negative things about Cloudfare so I#M not quite sure if it would really be a good idea to try them. But maybe that would by a last shot before trying that server thing.
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Server Error 500 under heavy load

Post by Timbalu »

How is "high traffic" and "not enough ressorces" exactly defined, in your case?
I still think that normal and quite busy sites can live in normal webhosting, without the boost of an own servers, as long as fundamental rules have taken place.
Use less or less expensive plugins, clean up your code, find the bottleneck in hard- or software, ask for some more Ressources, yes even have a deep look what your server logs say, etc.
Did you really follow Garvins quoted advice in detail?
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

What bad did you here about cloudflare? Since I'm useing it, this would interest me. Maybe you have a link or two?

tia
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

How is "high traffic" and "not enough ressorces" exactly defined, in your case?
According to my hoster it is about 40.000 unique visitors each day. On Monday it was 60.000 due to the WWDC keynote (my blog is about Apple). My hoster won't tell me about the actual ressources he provides me with but that seemed to be definately too much...

I also got in contact with Garvin and he also thinks that the problem should be on 1&1's side. A dedicated server might be a solution. But it's an expensive one.
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

What bad did you here about cloudflare? Since I'm useing it, this would interest me. Maybe you have a link or two?
Didn't find them anymore. But since it is always the case that people tend to complain instead of praising a service I thought I'd give it a try. The DNS servers are still updating so I cannot really tell if it works.

BTW, you developed the serendipity_event_proxy_realip, right?! I get the following error when trying to install it:

Code: Select all

Parse error: syntax error, unexpected ';' in /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php(62) : eval()'d code on line 1

== SERENDIPITY ERROR ==

Please correct:

Cannot modify header information - headers already sent by (output started at /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php(62) : eval()'d code:1) in /homepages/[...]/serendipity/serendipity_admin.php on line 11
Any ideas?!
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

Can you try changeing the code on line 62 from

eval('$realip_ip = ' . $realip_var . ';');

to

eval('$realip_ip = ' . $realip_var);
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

No. In that case I get this error:

Code: Select all

Parse error: syntax error, unexpected end of file in /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php(63) : eval()'d code on line 1

== SERENDIPITY ERROR ==

Please correct:

Cannot modify header information - headers already sent by (output started at /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php(63) : eval()'d code:1) in /homepages/[...]/serendipity/serendipity_admin.php on line 11
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

Please add before

eval('$realip_ip = ' . $realip_var . ';');

echo '$realip_ip = ' . $realip_var . ';';

and post the output of this line.
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Server Error 500 under heavy load

Post by Timbalu »

schimanke wrote:
How is "high traffic" and "not enough ressorces" exactly defined, in your case?
According to my hoster it is about 40.000 unique visitors each day. On Monday it was 60.000 due to the WWDC keynote (my blog is about Apple). My hoster won't tell me about the actual ressources he provides me with but that seemed to be definately too much...

I also got in contact with Garvin and he also thinks that the problem should be on 1&1's side. A dedicated server might be a solution. But it's an expensive one.
Yeah, 60K a day is way too much! As far as I know, i.e. from 57K visitors are 39K Spambots. It might depend a little bit on your site, since you are refering to the big "i"! But sorting out lots of spammers via suhosin, iptables, fail2ban, or even sharper tools, would let that server calm down quickly, I presume.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

After about one month after starting with cloudflare the "threats" started to decrease. Starting with about 50% threats I'm now at about 10%.
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

Please add before

eval('$realip_ip = ' . $realip_var . ';');

echo '$realip_ip = ' . $realip_var . ';';

and post the output of this line.

Code: Select all

$realip_ip = ;
Parse error: syntax error, unexpected end of file in /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php(64) : eval()'d code on line 1

== SERENDIPITY ERROR ==

Please correct:

Cannot modify header information - headers already sent by (output started at /homepages/[...]/serendipity/plugins/serendipity_event_proxy_realip/serendipity_event_proxy_realip.php:62) in /homepages/[...]/serendipity/serendipity_admin.php on line 11
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

It seems, that the var $realip_var has no value, allthough it has a default value. I'll write a fix and post it here, so you can try it.
schimanke
Regular
Posts: 161
Joined: Mon Jan 07, 2008 4:38 pm
Location: Hameln, Germany
Contact:

Re: Server Error 500 under heavy load

Post by schimanke »

Thanks! Looking forward to it.
kleinerChemiker
Regular
Posts: 765
Joined: Tue Oct 17, 2006 2:36 pm
Location: Vienna/Austria
Contact:

Re: Server Error 500 under heavy load

Post by kleinerChemiker »

Please test this. Your problem should be fixed.
Attachments
serendipity_event_proxy_realip.zip
(10.34 KiB) Downloaded 315 times
Post Reply