You are invited to Log in or Register a free Frihost Account!

>.<!! 500 internal server error and things I can't exp

When i am posting a long tutorial with 12434 characters in my own forum. I get 500 internal server error.

The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request.

This is what I have posted at phpbb support forum:

But when i post a topic/reply with short replies, it did not failed. Where has gone wrong??

When I do a test on my own computer's localhost/forums/(exactly the same copy i copied to the online host), I was able to post that long tutorial with 12434 characters.

So is there problem with mysql? Some kind of limit to the maximum character allowed or something?? I export and import back the database using phpmyadmin so where is the problem?? Thanks.. =(

This is what he replied me:
Generally speaking, a 500 error involves some problem on the server itself. In many cases, it is the addition of a module called "mod_security", which examines all page requests, and interrupts ones which its rules say might be an attack. Without knowing what the content was of the tutorial, or what you copied it from (assuming you were using copy/paste from another application), it could also be a problem with character encoding.

The first thing to check is to ask your host if they have installed "mod_security". If they have, the log should have an entry explaining why it prevented the post.

By the way - the database limit is 65,535 characters. Using ODBC or MS-SQL can impose other limits, which can be patched, but that should not affect you with MySQL.

Then I found this today morning:

hmm, this is funny. I tried again today. It still fail but i found something weird by doing this:

I post the tutorial part by part first, about 10 parts, the front part are all success. When i am at the 9th part, 500 internal server error occurs. Then I post the 9th part line by line. When it reach a line with a word 'from' it shows error 500. The 9th part has 5 words of 'from', the only 5 in my whole tutorial. So I replace all the 'from' with 'fr0m'. o to a zero. Then:
[quote]Your message has been entered successfully.[quote]
Now I continued the 10th part and I finished posting my whole tutorial.

So, now i copy a single line from the 9th part with a word 'from' inside and make a new reply to that topic. I paste it then submit. 'Your message has been entered successfully.' i am gonna faint.

Then I reply a new by pasting the whole tutorial with all 'from' changed to 'fr0m'. 500 error shows. >.<

then I post the 9th part with all 'fr0m' changed to 'from', It failed with 500 error. I erase all the from and fr0m, successful.

Then I post the 9th part with 'from'. 'Your message has been entered successfully.' >.<!!

I try making a new reply by pasting the whole tutorial all at once. 'Your message has been entered successfully.' >.<!!!!!!

2 more times I tried to paste again it failed with error 500.
But I successfully post the 9th part with all 'from' again.
This repeat and repeat, sometimes it passed sometimes it failed.

What is this...
Definitely mod_security getting in the way. Bet there is also a quote character in the message somewhere, and you're hitting a filter installed to prevent SQL injection attacks.

phpbb support team say that this problem is definitely with my host. So frihost has mod_security?
Yes it is most likely due to the server and probably due to mod_security which is installed with pretty strict rules on server 2 and a bit less strict rules on vps 1. Unfortunately I probably won't be able to fix it during next week, so you'll have to wait a bit. Sorry for that.
Related topics
Reply to topic    Frihost Forum Index -> Support and Web Hosting -> Web Hosting Support

© 2005-2011 Frihost, forums powered by phpBB.