1
votes

i am getting a 500 internal server error when editing the Main_Page in mediaWiki 1.16.

it was working fine before, it started to happen suddenly and i am not sure why is this happening.

creating/editing other pages work completely fine. it just happens when editing Main_Page.

someone please help.

i am using mediaWiki 1.16.

this is the error log:

[24-Jun-2011 07:41:49] "" is not a valid magic thingie for "interlanguage" 

[24-Jun-2011 07:41:49] PHP Warning: ini_set() has been disabled for security reasons in /home/britishi/public_html/wiki/includes/db/Database.php on line 371 

[24-Jun-2011 07:41:49] PHP Warning: ini_set() has been disabled for security reasons in /home/britishi/public_html/wiki/includes/db/Database.php on line 378

This is the .htaccess

RewriteEngine On
RewriteBase /wiki
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^wiki/(.*)$ ./index.php?title=$1 [PT,L,QSA]
RewriteCond %{HTTP_HOST} ^en\.sitename\.info$ [OR]
RewriteCond %{HTTP_HOST} ^www\.en\.sitename\.info$
RewriteRule ^/?$ "http\:\/\/en\.sitename\.info\/wiki\/Main_Page" [R=301,L]

RewriteCond %{HTTP_HOST} ^fr\.sitename\.info$ [OR]
RewriteCond %{HTTP_HOST} ^www\.fr\.sitename\.info$
RewriteRule ^/?$ "http\:\/\/fr\.sitename\.info\/wiki\/Main_Page" [R=301,L]

Ok Solved!

It was because of SubPageList3 extension i was using so i put an if statement in the SubPageList3.php to attach the hook only if the page being rendered is not an edit page.

1
Start logging errors in your php.ini file - when a 500 gets thrown, there will usually be something in the php error log to explain it. You should also look in your webserver's error log. - smcphill
Errors in the rewrite rules in the .htaccess file can also cause HTTP 500 errors, without much useful information in the error log. This would also explain why is the problem constrained to the main page (which tends to have its own rewrite rule). - Tgr
but is was working fine before, i have edited the main page lots of time before - Shaheer
i have put both the recent error log entry and .htaccess content in my question details - Shaheer
Can you disable all the extensions in LocalSettings.php and try to narrow down if one of them is causing it? - bcoughlan

1 Answers

1
votes

A 500 error means the script had an error and couldn't be run. Typically you will find a more detailed error message in a log file: /var/log/messages or the Apache error log (typically /var/log/httpd/error_log). That should get you enough information to at least narrow down the source of the issue.