Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 8 of 8
  1. #1
    Member
    Join Date
    Mar 2005
    Posts
    72

    Default phpsuexec returns 500 error

    I've just installed cPanel on a fresh CentOS 4.2 server, it's a p4 3.0ghz with 512mb ram & 300gb sata hdd. It's on 10mbit line.

    I've got apache working ok but just rebuilt with phpsuexec and php 4.3.11 but all i get is 500 errors with phpbb & phpinfo file.

    Php info file is just normal
    PHP Code:
    <?php
    phpinfo
    ();
    ?>
    but it says "imature script headers" and error 500.

    Any ideas??

    Regards,
    Iain Shortreed

  2. #2
    BANNED
    Join Date
    Jul 2005
    Posts
    537

    Default

    rm -f /tmp/sess*
    /etc/init.d/httpd restart

  3. #3
    Member
    Join Date
    Mar 2005
    Posts
    72

    Default

    Gave that a try just now but still having this error :/

  4. #4
    Member
    Join Date
    Jun 2005
    Posts
    124

    Default

    Run in WHM: fix insecure permissions, or chmod the files to 755

  5. #5
    Member
    Join Date
    Mar 2005
    Posts
    72

    Default

    No joy, still stuck with that error. Have run that in whm many times already and have tried chmoding, chowning.

    Edit: Looked through suexec_log and found lots of errors but i have no idea what they mean. Any ideas?

    take a look at my suexec log
    Last edited by Xenon101; 11-03-2005 at 07:37 AM.

  6. #6
    Member
    Join Date
    Jan 2005
    Posts
    1,880

    Default

    Quote Originally Posted by Xenon101
    No joy, still stuck with that error. Have run that in whm many times already and have tried chmoding, chowning.

    Edit: Looked through suexec_log and found lots of errors but i have no idea what they mean. Any ideas?

    take a look at my suexec log
    I'm getting a timeout trying to access that file. Can you post the errors from suexec_log in this thread?

    As for getting PHP scripts to work with phpsuexec enabled:

    1) Ensure that the permissions do not exceed 0755. Unless otherwise needed, my PHP scripts run happily with 0644 permissions. Same applies to the directory the script is in, apart from public_html which should have 0750 permissions (at least for me).

    2) Ensure that the ownership is relevantuser:relevantuser and not nobody:nobody. Ditto for the directory, apart from public_html which should always be owned by 'relevantuser' and belong to the group 'nobody'.

    3) Ensure that scripts are uploaded in ASCII and not BINARY mode when ftping. If in doubt, delete and reupload - this one generally gets you a 'premature end of headers' type error.

    Check the above three points and then check them again. If you're still encountering script execution errors, post back the relevant lines only from your suexec_log AND check the above three points again.

  7. #7
    Member
    Join Date
    Mar 2005
    Posts
    72

    Default

    phpsuexec log:
    Code:
    [2005-11-02 22:32:13]: info: (target/actual) uid: (iain/iain) gid: (iain/iain) cmd: phpinfo.php
    [2005-11-02 22:32:13]: error: target uid/gid (32003/32003) mismatch with directory (32003/99) or program (0/0) or trusted user (0/10)
    That's just repeated a few times.

    Edit: Fixed with a chown iain:nobody on pub html & iain:iain on php file cheers!
    Last edited by Xenon101; 11-03-2005 at 08:01 AM.

  8. #8
    Member
    Join Date
    Jan 2005
    Posts
    1,880

    Default

    Good to hear that the problem is sorted out, and that the 3 magic phpsuexec rules still work!

Similar Threads & Tags
Similar threads

  1. Frontpage Administration returns error
    By jandafields in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 06-18-2007, 10:00 AM
  2. phpsuEXEC - causes 500 errors on some sites
    By trigger hippy in forum cPanel and WHM Discussions
    Replies: 18
    Last Post: 08-25-2006, 11:47 AM
  3. phpsuexec support 500
    By Secret Agent in forum cPanel and WHM Discussions
    Replies: 2
    Last Post: 07-24-2006, 08:39 AM
  4. If Perl produces a 500 server error would phpsuexec as well?
    By jackie46 in forum cPanel and WHM Discussions
    Replies: 4
    Last Post: 10-16-2005, 12:17 PM
  5. phpsuexec support...500 error
    By I Love Jesus in forum cPanel and WHM Discussions
    Replies: 9
    Last Post: 12-15-2004, 06:31 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube