Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 8 of 8
  1. #1
    Member
    Join Date
    Jul 2010
    Posts
    30

    Default 500 Internal Server Error With PHP Scripts/Files

    I have 12+ years experience in enterprise level IT, but with Windows-based servers... so please bear with me.

    I am trying to migrate 8 websites from one of my old CentOS 5.5 VPSs that was running ISP Manager over to my new CentOS 5.5 VPS that is running cPanel/WHM. All of the files and scripts were running fine on the retired server under ISP Manager, but are now dead on arrival on the new server.

    I have all of the files moved over, the databases created and the various settings config files edited, but when I navigate to any PHP run script like WordPress I get a 500 Internal Server Error. I can navigate and use HTML files just fine, but it's the PHP files that throw up.

    Some of the PHP scripts I'm running are WordPress, Simple Machines Forum, vBulletin, HostBill, Magento and a few "one off" PHP scripts like simple shopping carts and mailing lists. I also have no problem navigating and using any part of cPanel or WHM.

    To initially move the files over in a quick manner I TAR'd them on the original server, and then used WGET to download them on the new server... from there I uncompressed them and CHMOD'd them based on their recommended settings. I had used this method in the past without much issue, and it was certainly faster than using FTP as I moved about 70,000 files total.

    Checking the PHP settings on my server via WHM it seems to be running PHP5 with suphp as the handler, the settings can be viewed HERE. The basic PHP Configuration Editor settings can be viewed HERE... and nothing seems out of the ordinary.

    Now as stated, I am a Linux and PHP novice but I can manage my way around a server. I also have PHP scripts running just fine on another server with cPanel that has the same specs and image, so I'm figuring that this is all a permissions issue. I've read some of the other topics on this but replies are all over the place so I'd prefer answers that seem to be inline with my current situation.

    Any and all help is greatly appreciated, and I'll be happy to provide further information if needed... as this is a huge priority with me as I have so many websites down at the moment.

    EDIT: I forgot to mention that I did NOT copy over the old .htaccess files, and I have confirmed that .htaccess files aren't the problem, as I've deleted them and still have the problem.
    Last edited by TorchServers; 08-03-2010 at 06:15 PM.

  2. #2
    cPanel Partner NOC cPanel Partner NOC Badge
    Join Date
    Oct 2003
    Posts
    1,928

    Default

    tail or chevk your error log

    /user/local/apache/logs/error_log
    Lowest Host/Empire Technology LLC
    Affordable hosting solutions http://empire-hosting.net
    List Your hosting site FREE in http://hostgeneration.com

  3. #3
    Member
    Join Date
    Jul 2010
    Posts
    30

    Default

    What I see in the logs when I visit a WordPress installation is... "Mismatch between target UID (510) and UID (501)"

    Code:
    [Tue Aug 03 20:04:13 2010] [error] [client 98.195.78.211] SoftException in Application.cpp:422: Mismatch between target UID (510) and UID (501) of file "/home/user/public_html/index.php"
    EDIT: I've seem to have gotten it working, although I have some further permission errors to work through.

    Using chown +R user:user /home/user/public_html/ seems to do the trick for the most part, as found in this post.
    Last edited by TorchServers; 08-03-2010 at 09:42 PM.

  4. #4
    cPanel Partner NOC cPanel Partner NOC Badge
    Join Date
    Oct 2003
    Posts
    1,928

    Default

    /srcipts/chownpublichtmls would have down the trick
    Lowest Host/Empire Technology LLC
    Affordable hosting solutions http://empire-hosting.net
    List Your hosting site FREE in http://hostgeneration.com

  5. #5
    Member
    Join Date
    Jul 2010
    Posts
    30

    Default

    Quote Originally Posted by dalem View Post
    /srcipts/chownpublichtmls would have down the trick
    Thanks! I ran that just to be sure I did them all.

  6. #6
    Member
    Join Date
    Jul 2010
    Posts
    30

    Default

    I seem to still be having permission issues all over my server... my "time saving" technique has turned out to be a nightmare on this cPanel server. While I can now access the index.php of my WordPress and other scripts any time I click any links I get 404 file not found errors.

    I ran the EasyApache updated and the chown script and am still having issues... I'm kind of at wits end. Any new script I install from scratch works just fine with the exception of IonCube Loader, but all of the ones I copied over fail.

  7. #7
    Registered User
    Join Date
    Apr 2011
    Posts
    4

    Default Re: 500 Internal Server Error With PHP Scripts/Files

    Quote Originally Posted by TorchServers View Post
    I seem to still be having permission issues all over my server... my "time saving" technique has turned out to be a nightmare on this cPanel server. While I can now access the index.php of my WordPress and other scripts any time I click any links I get 404 file not found errors.

    I ran the EasyApache updated and the chown script and am still having issues... I'm kind of at wits end. Any new script I install from scratch works just fine with the exception of IonCube Loader, but all of the ones I copied over fail.
    Are you runing Suphp and you have enabled mod_userdir?

    if that correct see this thread to see if you resolve it:

    500 Internal Server Error with PHP file

    See you..

  8. #8
    Registered User
    Join Date
    Apr 2011
    Posts
    4

    Default Re: 500 Internal Server Error With PHP Scripts/Files

    Quote Originally Posted by TorchServers View Post
    I seem to still be having permission issues all over my server... my "time saving" technique has turned out to be a nightmare on this cPanel server. While I can now access the index.php of my WordPress and other scripts any time I click any links I get 404 file not found errors.

    I ran the EasyApache updated and the chown script and am still having issues... I'm kind of at wits end. Any new script I install from scratch works just fine with the exception of IonCube Loader, but all of the ones I copied over fail.
    If you are running Suphp and you have issues with mod_userdir see this thread:

    http://forums.cpanel.net/showthread.php?p=850632

Similar Threads & Tags
Similar threads

  1. Replies: 2
    Last Post: 06-07-2011, 08:32 PM
  2. 500 Internal Server Error in all php pages
    By rohan_ in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 06-07-2011, 03:56 PM
  3. 500 Internal Server Error with PHP file
    By LSteamGeo in forum cPanel and WHM Discussions
    Replies: 26
    Last Post: 05-19-2011, 12:03 AM
  4. 500 internal server error on all 3rdparty scripts
    By saweb in forum cPanel and WHM Discussions
    Replies: 20
    Last Post: 02-11-2010, 08:53 AM
  5. schlabo scripts- 500 internal server error
    By anish sidhan in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 12-31-2003, 10:53 AM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube