Error 500 on all static pages

Found a bug? Tell us!!
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Error 500 on all static pages

Post by yellowled »

I just realized one of my dev blogs is no longer delivering static pages. Any static page (even newly created ones) results in a 500 error. (“Internal Server Error. The server encountered an internal error or misconfiguration and was unable to complete your request.”) However, this does not happen on e.g. the contact form or the archives.

s9y 1.7-rc4 with Static Pages 4.00 on Apache 2.2.3 with PHP 5.4.11. Tested with 2k11, BP and default, so it's probably not related to the template. Unfortunately, I do not have access to error logs on this server.

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Is that a question YL?
A 500 Internal Server Error needs you to search what the logs say.
So you do need to ask your service provider first.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

Timbalu wrote:A 500 Internal Server Error needs you to search what the logs say.
I wasn't aware of that. Also didn't see a point in keeping this to myself. Might be someone else is experiencing the same issue or knows of any recent changes which might be related to this.

I'll see what I can do to get access to the error.log.

YL
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

I know have an error.log, but for the wrong of my two account with Uberspace. However, this error log relates to my blog, running on 1.6.2, and it might be interesting as well, although probably not related to the static pages issue:

Code: Select all

mod_fcgid: stderr: PHP Strict Standards:  Only variables should be assigned by reference in /var/www/virtual/mees/html/include/functions_smarty.inc.php on line 73
There are quite a lot of those with various line numbers.

I'll report back when I have access to the error.log on the other account as well.

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

yellowled wrote:However, this error log relates to my blog, running on 1.6.2,

Code: Select all

mod_fcgid: stderr: PHP Strict Standards:  Only variables should be assigned by reference in ...
That for sure as you are running PHP 5.4.11! Does it only note to the error.log or also in blog context? If the last, you might need to add some additional error_reporting, since E_ALL includes E_STRICT in PHP 5.4.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

Timbalu wrote:That for sure as you are running PHP 5.4.11! Does it only note to the error.log or also in blog context? If the last, you might need to add some additional error_reporting, since E_ALL includes E_STRICT in PHP 5.4.
Nope, just in the error.log. Also, this is my “real” blog which is still running on 1.6.2 – so those will probably be addressed in 1.7, right?

Anyway, I now have an error log for my staging area, which on calling a static page in 1.7-rc4 says:

Code: Select all

(104)Connection reset by peer: mod_fcgid: error reading data from FastCGI server, referer: http://s9y.netzgestaltung.net/
Premature end of script headers: php-fcgi-starter, referer: http://s9y.netzgestaltung.net/
YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Yes. At least they should. But I don't know if we have caught them all ...

The premature end error can be 3 things.
It describes the situation that the php-fcgi-starter waits for itself or a responding script and quits telling you that it hasen't finished processing.

This can be the cgi-bin/php-fcgi-starter file itself, missing the correct permissions to process or
a missing restart of itself (while some other things have changed) or
some other serendipity files which throw unresponding errors.
In the last case we would need a better error log entry (maybe also look into in suexec.log).

The easiest way would be to ask the uberspace team first.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

Timbalu wrote:The easiest way would be to ask the uberspace team first.
(Note: I won't translate the German answer of the Uberspace team here in order to not make any translation errors, but I also don't want to switch the thread to German.)
Zu der URL "http://s9y.netzgestaltung.net/testseite.html" gibt es keine passende Datei:

$ ls /var/www/virtual/<USER>/s9y.netzgestaltung.net/testseite.html
ls: /var/www/virtual/<USER>/s9y.netzgestaltung.net/testseite.html: No such file or directory

Du rufst hier also *keine* statische Datei auf. Der Webserver bemerkt nun das Fehlen dieser Datei und verhält sich dann so, wie Deine Konfiguration für ihn es hier verlangt: er übergibt das an Deine Webapplikation, die dann aber irgendwie mit dieser Eingabe nicht klar kommt und in einen Fehler läuft. Die Fehlermeldung klingt sehr danach, als ob der PHP-Interpreter beim Ausführen dieses Skriptes abstürzt.

Du könntest hier prinzipiell mal mit verschiedenen PHP-Versionen experimentieren. Derzeit ist bei Dir PHP 5.4.11 voreingestellt, es gibt aber leider noch ziemlich viel PHP-Software, die mit PHP 5.4 nicht kompatibel ist.
I would assume that it works with PHP versions earlier then 5.4, but haven't tested that yet. Will do in a bit, though.

YL
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

yellowled wrote:I would assume that it works with PHP versions earlier then 5.4, but haven't tested that yet. Will do in a bit, though.
Okay, so Uberspace does not offer just any PHP version, but here's what I found out:

– PHP 5.3.21 (latest 5.3 available): static pages work
– PHP 5.4.0 (earliest 5.4 avaibale): static pages throw a 500 error

Also, with PHP 5.3.x, there's no entries in the error.log at all.

I can do more testing if it helps, just let me know what you need tested.

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

Timbalu wrote:Fixed in 4.01
Still throws a 500 with that on PHP 5.4.11. Same error messages in error.log. Works fine with PHP 5.3.21.

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Hmmm, I came up with this testing locally a 5.4.11 (mod Installation) ... which fixed a thrown reference error...
Did you clean templates_c?
Do you get a Status 200 OK?
What else happens?
Don't you get any stack trace error reporting?
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
yellowled
Regular
Posts: 7111
Joined: Fri Jan 13, 2006 11:46 am
Location: Eutin, Germany
Contact:

Re: Error 500 on all static pages

Post by yellowled »

Timbalu wrote:Did you clean templates_c?
Do you get a Status 200 OK?
What else happens?
Don't you get any stack trace error reporting?
Yes, I cleaned out templates_c. No, I do not get a 200, but that might be due to some limitations on the access.log (not sure how often those are updated to my user account). All I get is the standard 500 internal server error page, just like before.

http://s9y.netzgestaltung.net/testseite.html

YL
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Yes I see... its this (fastcgi) and not the reference error (any more):
Die Fehlermeldung klingt sehr danach, als ob der PHP-Interpreter beim Ausführen dieses Skriptes abstürzt.
Which could be due to be a buggy PHP fcgi version... or the permissions... I don't really think it is the staticpage redirect....
I for myself do not really know what to do now, else then downgrading... and tell uberspace that PHP 5.4.11 staticpage is working if not in fcgi... mode.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Timbalu
Regular
Posts: 4598
Joined: Sun May 02, 2004 3:04 pm

Re: Error 500 on all static pages

Post by Timbalu »

Could you find out what the suexec.log says exactly?
These

Code: Select all

Connection reset by peer: mod_fcgid: error reading data from FastCGI server, 
errors ending up with "premature end" can be runtime errors or the use of PRM (http://www.rfxn.com/projects/process-resource-monitor/). It could be worth of trying to disable this (if they use it on uberspace). There are lots of other different solutions out there if you google this. So that really might be something for the uberspace support to solve.
Regards,
Ian

Serendipity Styx Edition and additional_plugins @ https://ophian.github.io/ @ https://github.com/ophian
Post Reply