SMF Support > SMF 2.0.x Support

Frequent internal server error 500 + unable to backup database

(1/11) > >>

krystal:
My forum: http://www.playmofriends.com/forum/index.php
Running SMF 2.0.15
PHP Version 5.6.36 (http://www.playmofriends.com/phpinfo.php)
Caching Level - No caching


I upgraded my forum to 2.0.15 back in January and everything had been running perfectly until about a month ago.
Suddenly forum users were getting repeated 500 errors in all sorts of different places. There doesn't seem to be any pattern - they happen randomly on any page, sometimes even when trying to reply to a post or send a personal message. The pages can always be reached after a refresh (or sometimes two) so nothing is actually missing as far as I can tell.

I wrote to my webhost (Dreamhost) who I have been with since 2005, and they have offered a few suggestions but nothing has worked so far. They observed that there was high traffic so I added some code to the .htaccess to block all the unwanted bots. I also enabled debugging for them, but they weren't able to gain anything helpful from it. In their opininon the errors are not due to "overly utilizing the servers resources."

Additionally, I have an even more serious problem where I am unable to download a backup of the database. It tries to load and eventually times out and returns a File Not Found error. Very worrying!

The error log seems to be full of the same type of message each time this happens:

Premature end of script headers: php56.cgi, referer: http://www.playmofriends.com/forum/index.php?board=14.0
File does not exist: /home/playmo/playmofriends.com/internal_error.html, referer: http://www.playmofriends.com/forum/index.php?board=14.0

I hope I have provided enough information. Even after all this time, I'm not very experienced at this stuff.  :-[

GigaWatt:
If you'e got cache enabled... don't move a muscle.

We've been seeing these 500 errors related to corrupted cache files and would like to debug it. As I can see, you forum still emits the 500 error, so what we would like is a dump (a copy) of the cache folder's content and the error log of the forum. The first can be obtained via FTP from your webspace (it's the cache folder in the forum's root directory). If you're not sure whether you're using caching or not, open up the cache folder. If the only files present in the cache folder are .htaccess and index.php, you're not using caching and the 500 error is probably not related with the cache setting. But, if you are, we would appreciate if you could copy the content (download it) from the cache folder and share it here on the forum. You could archive the content (zip will do just fine) and if the archive is too big to be attached as an attachment on the forum, you could share it through some file sharing site (zippyshare offers uploads up to 200MB in file size).

About the admin error log... it should reside in the database (I'm kind of slow today... can't really remember at the moment, if some of the members remember the exact place of the forum's error log, please correct me). In any case, a database dump could also be helpful.

About not being able to dump the database, do the following. Open up phpMyAdmin, select the database, go to the Export tab, select "Custom - display all possible options", in the Output settings in the Compression settings, select "zipped", scroll down to the end and click on "Go". Try it like this and report back ;).



I'm sorry for not giving you the answer straight away, but if you are using forum cache and the 500 error is related to caching, we would loose all forensic material if I told you how to fix it right away :S. Once again, I'm sorry...

krystal:
Thank you for your help! I managed to download a backup of the database using your detailed instructions  :)

I don't have cache enabled. I checked the folder and it only contains .htaccess and index.php

On the caching page in Server Settings there is a message in red: SMF has not been able to detect a compatible accelerator on your server.

I guess this is going to make it a lot harder to debug  :(

Do you still need a copy of the error log? You mean the one on the server in the logs directory or a different one?

GigaWatt:

--- Quote from: krystal on July 10, 2018, 08:06:51 PM ---On the caching page in Server Settings there is a message in red: SMF has not been able to detect a compatible accelerator on your server.
--- End quote ---

Yep, this means that your host doesn't support caching, but don't worry about it not supporting caching.


--- Quote from: krystal on July 10, 2018, 08:06:51 PM ---I guess this is going to make it a lot harder to debug  :(
--- End quote ---

Yeah... kind of... we'll see ;).


--- Quote from: krystal on July 10, 2018, 08:06:51 PM ---Do you still need a copy of the error log? You mean the one on the server in the logs directory or a different one?
--- End quote ---

If you could access your server's error log, yes, that would be preferable. And a copy of the most recent error logs from the forum's admin panel too ;).

krystal:

--- Quote from: GigaWatt on July 10, 2018, 08:17:08 PM ---If you could access your server's error log, yes, that would be preferable. And a copy of the most recent error logs from the forum's admin panel too ;).

--- End quote ---

I hope what I have attached is the correct file :)

I checked the error log on the forum (which I cleared prior to June 26 when trying to do some maintenance).
There are only 11 logs and they are all for "Password incorrect" from various users.


Dreamhost replied in the meantime and said they noticed a number of hits showing this:

Request exceeded the limit of 10 internal redirects due to probable configuration error.
Use 'LimitInternalRecursion' to increase the limit if necessary.
Use 'LogLevel debug' to get a backtrace.

I don't know how to do the debug it suggests. :-[

The DH support guy suggested adding a rewrite rule for 'LimitInternalRecursion' to .htaccess to see if it will help.
Could you please tell me the actual code I need to put in and does it matter if it goes at the start or end of the file?

Thanks again!


Navigation

[0] Message Index

[#] Next page

Go to full version