Drupal 500 Internal Server Error on shared hosting

Was getting irregular "500 Internal Server Error" pages on a new Drupal 6 install, running on shared hosting.

After some research it appears that the hosting company is running php5 as CGI which does not follow the PHP directives set in Drupal's .htaccess file:

# PHP 4, Apache 1.
<IfModule mod_php4.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

# PHP 4, Apache 2.
<IfModule sapi_apache2.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

# PHP 5, Apache 1 and 2.
<IfModule mod_php5.c>
  php_value magic_quotes_gpc                0
  php_value register_globals                0
  php_value session.auto_start              0
  php_value mbstring.http_input             pass
  php_value mbstring.http_output            pass
  php_value mbstring.encoding_translation   0
</IfModule>

This post suggests commenting out these PHP specific settings, and adding the following to your php.ini (if you have access to it - some hosting companies don't allow this, although there are workarounds):

magic_quotes_gpc                0
register_globals                0
session.auto_start              0
mbstring.http_input             pass
mbstring.http_output            pass
mbstring.encoding_translation   0

This seems to work - I'll update in the comments if I run into this issue again.

Comments

Thanks

It's wonderful code, Thanks for share!

php_value magic_quotes_gpc 0
php_value register_globals 0
php_value session.auto_start 0
php_value mbstring.http_input pass
php_value mbstring.http_output pass
php_value mbstring.encoding_translation 0

Data Recovery Software|Guard Process|Restore Deleted Files|进程保护|Recover Deleted Pictures From Memory Card

This is only an issue for

This is only an issue for some of the server OS(open source) and it is valid for all the OSs. This can be eliminated by doing a slight modification to .htaccess file. Not that difficult. michael jackson cds

I've come to the following

I've come to the following solution, for anyone who's struggling likewise. The problem was one of my own misunderstanding. I prepared my finished, offline Drupal site as if for an upgrade. I uninstalled all contributed modules and changed the site's theme to a default one. I then did a manual, fresh installation of Drupal on the hostican server. After installing Drupal, I deleted the mysql database I had used for the installation, and created a new database with the same name (and user and password) and imported my database from my finished Drupal site on my computer (changed name of database as found in .sql file to match the one on the server before importing). I then replaced the [site name]/sites/all folder in my Drupal installation on the server with the one from my finished site (this folder includes contributed modules and themes). After the above was successfully completed, I re-installed all contributed modules and did a database update (ran the update.php script). As far as I can tell, the site is fully functional.

----
Sincerely,
Collection of dark maple syrup

The server encountered an

The server encountered an internal error or misconfiguration and was unable ... Additionally, a 500 Internal Server Error error was encountered.
Be a movie extra

Drupal is the my favorite web

Drupal is the my favorite web platform to use.
Regards,
SEO

If you are running your own

If you are running your own root, dedicated or virtual server this is an easy bugfix: You just have to change the php.ini of your server and provide more memory to your PHP installation. On a shared hosting server – like at the webhosting solutions at 1and1 you often don’t have access to that central php.ini affiliates

My new website

I have seen this happening with the web hosting I was dealing with.
But since I started my new web site for model trains, I kept in mind to find a reliable web hosting for not facing these troubles again.

About 3 to 4 months later all

About 3 to 4 months later all the sites showing "500 Internal Server Error" everytime I try to log in to admin account.I couldn't.
Toronto escorts

Drupal's error

I think Drupal have answers of this error and why this happen. We are waiting for this response...Thanks.. used cars Ottawa

It's not SQL at all. It's the

It's not SQL at all. It's the global settings for Apache, restricting the amount of control your local settings for apache (.htaccess) can do.Try removing (commenting) the 'Options' lines in your .htaccess. Those are the ones that usually cause this error, and should still leave you with the clean_urls goodness.

Jason from Ohio,
admin @ Audi Contract Hire Leasing

Drupal

Drupal is a very powerful platform, feature rich, trouble free &it supports many applications. I think it makes a big difference, using Drupal for your business websites, giving it flexibility applying more options. anonymous surfing

I am a big fan of this

I am a big fan of this singer. v-pills gold film seyret

Thanks

I have had this error before and now I understand the solution. The is natural cure to hair loss for men and women and that is with Provillus that target cause of hair loss with natural ingredients. Wartrol is also a natural genital warts relief.

We can use this code after

We can use this code after few changes to our system Regards, Granite Worktops

I was repeatedly getting this

I was repeatedly getting this error for quite some time, and i went to discuss this issue in drupal forums and here is what i have got from them, Error 500 can be related to any issue and its very rarely related to drupal, The only time I've ever seen Drupal cause a server error is when the .htaccess file has been corrupted,You could try temporarily deleting the .htaccess file to see if that fixes it.Actually this solution worked well for me i and i got out of it, you should try this and see if the problem still persists clothing | jewelry

If you have the Root

If you have the Root privileges then you can definitely access the PHP specific settings. Then you can correct the settings. western mediterrananean cruises

This is not a problem merely

This is not a problem merely occurred due to shared hosting. I think it is a bug in this drupal version that has to be addressed in the next release of patch. Warrock hacks

When we talk with a FINANCIAL

When we talk with a FINANCIAL SUCCESS Adviser we are in control. The initial discussion is absolutely under no obligation. home loan calculator

Hi webmaster, commenters and

Hi webmaster, commenters and everybody else !!! The blog was absolutely fantastic! Lots of great information and inspiration, both of which we all need!b Keep 'em coming... you all do such a great job at such Concepts... can't tell you how much I, for one appreciate all you do! Application Hosting

We received this error on one

We received this error on one of our domains as well. Still investigating what is going on since other Drupal sites run just fine on the same server.

Shared hosting has

Shared hosting has significant limits. You never know exactly how many othe rsites are on the server. What resources are being used. The list goes on. If you have a lot of modules (no we can't tell you what a lot is, it's subjective) you may be running into processor timeouts on the host. You need to see what tools are available from your host to track down those sorts of issues. Harry

This issue might be occurring

This issue might be occurring due to the OS used in the server. Different OSs reacts in different ways. sell photos online

It is seemed to be a bug in

It is seemed to be a bug in the newer version in Drupal. It was working fine in the earlier version. Hope this will be worked out. epilator

While I was doing a homework

While I was doing a homework help for my son, I encountered the same problem. Has anyone found out the solution to avoid this? I've been reading other forums, reviews, research papers and surfing to other sites looking for the best solution on this but it seems no one hasn't found one. dictionar german

Nice Post

Hi, I found your post on google. I just added you to my Google News Reader. Keep up the good work. Look forward to reading more from you in the future.
Regards,
Jone
automotive parts

If you are running your own

If you are running your own root, dedicated or virtual server this is an easy bugfix: You just have to change the php.ini of your server and provide more memory to your PHP installation. On a shared hosting server – like at the webhosting solutions at 1and1 you often don’t have access to that central php.ini affiliates

It's not SQL at all. It's the

It's not SQL at all. It's the global settings for Apache, restricting the amount of control your local settings for apache (.htaccess) can do.Try removing (commenting) the 'Options' lines in your .htaccess. Those are the ones that usually cause this error, and should still leave you with the clean_urls goodness.I believe that Options +Follow SymLinks doesn't help a normal install of Drupal much, but is something a host providor may choose to lock down - and thus cause an error. Kill that line. free ads |job|electric adjustable bed

This problems some time

This problems some time occurs in dedicated servers as well. I have come across such occasions. Sometimes it is not easy to solve via accessing remotely. Metaphysics

I really appreciate drupal

I really appreciate drupal for figuring out such error and preventing it's users from facing it in future. term paper help | theses

Darn! Now I see where it was

Darn! Now I see where it was putting an error for my drupal site. dissertation help | essay help | researchpaper

It is difficult to track down

It is difficult to track down 500 errors, but we need to check file permissions and further at the scripts themselves. For example, if we are using an online shopping cart script club penguin cheats

Drupal web sites give many

Drupal web sites give many bugs even it's a FOSS related. Thanks Umman from driving licence

i think this is needed php

i think this is needed php code for every code developers. regards, talent agencies

when i first install drupal

when i first install drupal in the root directory - install.php doesnt come up, instead a 500 internal server error does.... Christmas ringtones

Honestly, it's probably your

Honestly, it's probably your shared hosting. You should read about in this managed hosting whitepaper. It will help you understand how it can help improve your website performance while limiting the costs typically associated with managed hosting.

Great post, thanks for

Great post, thanks for sharing. Businesses are happening all around the world. ..here information should be helpfully for us...Replacement Windows Milwaukee

It is difficult to track down

It is difficult to track down 500 errors, but we need to check file permissions and further at the scripts themselves. For example, if we are using an online shopping cart script Voucher Codes

tgb

Please give more details regarding this error and how to avoid that? flooring

This is a common error, We

This is a common error, We can't fix it. Dion Interserv Direct Inc

Where we can implement this

Where we can implement this code. In my laptop I have installed virtual box and ubuntu. I ma planing to start apache web server. Regards, music downloads

good

Choose, buy and shop for on sale tiffany jewelry including Tiffany & Co Silver Necklace, Pendants, Bangles, Bracelets, Earrings, Rings and Accessories. tiffany jewelry We will surprise to find the high quality in much. Everyone will focus on tiffany and co Tiffany Bracelets Tiffany Earrings Tiffany Necklaces links of london

When I do article submit in

When I do article submit in the web directory, I get same error. How do i prevent it?

I recieve the error "Error

I recieve the error "Error 500 - Internal server error" anytime I click on a link on ... I have changed the line..what's that problem? Improve credit

I really appreciate your

I really appreciate your posting here. It is really helpful everybody's in here. One little question, I cannot find the htaccess files and php.ini, where is it located? - restaurantes madrid

In any kind of a ceremony,

In any kind of a ceremony, finally the pictures and the videos may the ONLY things that were retain for some time.Other all will be vanished very soon. Thesis Writing. Regards,

rtn

What is drupal 500 internal server error on shared hosting? public relations melbourne

Drupal was also designed to

Drupal was also designed to allow new features and custom behavior to be added to extend Drupal's core capabilities. Julie, SEO

500 Internal Server Error in

500 Internal Server Error in Admin Areas PHP / MySQL Assistance. ... on my personal computer onto my shared server here at hostican. Wedding invitations

Tags for Drupal 500 Internal Server Error on shared hosting