The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Correct way to enable PHP SuExec

Discussion in 'General Discussion' started by Daniel15, Oct 27, 2006.

  1. Daniel15

    Daniel15 Well-Known Member

    Joined:
    Oct 7, 2006
    Messages:
    84
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Melbourne, Australia
    cPanel Access Level:
    Root Administrator
    Hi,
    I've been trying to enable PHP SuExec on a server, but I'm having a few problems. I compiled Apache and PHP via the 'Apache Update' option in WHM. All seems to be going well (Apache starts), but when I try to access a PHP file, I get an 'Internal Server Error' message. The error log states something like:
    Code:
    [Fri Oct 27 23:41:47 2006] [error] (8)Exec format error: exec of /usr/local/apache/htdocs/phpinfo.php failed
    [Fri Oct 27 23:41:47 2006] [error] [client 202.7.176.134] Premature end of script headers: /usr/local/apache/htdocs/phpinfo.php
    
    Since I have no experience with cPanel-based servers, I'm not sure what to do to fix this. Does anyone know?
     
  2. jayh38

    jayh38 Well-Known Member

    Joined:
    Mar 3, 2006
    Messages:
    1,215
    Likes Received:
    0
    Trophy Points:
    36
    what does this give you?

    service httpd configtest
     
  3. Daniel15

    Daniel15 Well-Known Member

    Joined:
    Oct 7, 2006
    Messages:
    84
    Likes Received:
    0
    Trophy Points:
    6
    Location:
    Melbourne, Australia
    cPanel Access Level:
    Root Administrator
    Doesn't matter, I seem to have fixed it.
    I was running PHP as an Apache module for a while, but I wanted to try PHP SuExec again, so I ran /scripts/easyapache today. This time, it worked perfectly :)

    There's still one script (Cacti) that gives that error, though, but most hosted sites seem to be working fine :D
     
Loading...

Share This Page