Page 1 of 2 12 LastLast
Results 1 to 15 of 17

Thread: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5.4.4

  1. #1
    Registered User
    Join Date
    Jul 2012
    Location
    Arapiraca, Brazil
    Posts
    2
    cPanel/WHM Access Level

    Root Administrator

    Question PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5.4.4

    I tried to update my PHP 5.3.14 to 5.4.4 (EasyApache), but I can not select "PHP Handler" (none) and "Default PHP Version" (empty).

    I've tried: http://forums.cpanel.net/f5/php-hand...ml#post1176111

  2. #2
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Could you also try bumping it to unlimited then in WHM > Tweak Settings > Max cPanel Process Memory? If that still doesn't work, please check /usr/local/cpanel/logs/error_log when loading WHM > Apache Configuration > PHP and SuExec Configuration area. If you do not see errors, please try running the update in command line. First, check the current settings:

    Code:
    /usr/local/cpanel/bin/rebuild_phpconf --current
    After that, set it using this type of example:

    Code:
    /usr/local/cpanel/bin/rebuild_phpconf 5 none suphp 1
    The above represents 5 as PHP 5 being default handler, none for PHP 4, suphp for PHP 5 hanlder, and 1 for suEXEC being enabled. If you want a different handler for PHP 5 than suphp, enter either dso or fcgi there instead.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  3. #3
    Registered User
    Join Date
    Jul 2012
    Location
    Arapiraca, Brazil
    Posts
    2
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Code:
    /usr/local/cpanel/bin/rebuild_phpconf 5 none suphp 1
    The above represents 5 as PHP 5 being default handler, none for PHP 4, suphp for PHP 5 hanlder, and 1 for suEXEC being enabled. If you want a different handler for PHP 5 than suphp, enter either dso or fcgi there instead.
    Returning: "Invalid combination. PHP5 is not available. Please rebuild apache if you require this configuration."

    and after the upgrade:

    Code:
    /usr/local/cpanel/bin/rebuild_phpconf --current
    
    Available handlers: suphp dso cgi none
    DEFAULT PHP: 5
    PHP4 SAPI: none
    PHP5 SAPI: none
    SUEXEC: enabled
    RUID2: not installed

  4. #4
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Quote Originally Posted by Brunomiova View Post
    I tried to update my PHP 5.3.14 to 5.4.4 (EasyApache), but I can not select "PHP Handler" (none) and "Default PHP Version" (empty).

    I've tried: http://forums.cpanel.net/f5/php-hand...ml#post1176111
    I have the same issue. :| Any suggestion would be appreciated.

  5. #5
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    The error in the log refers to the directive magic_quotes_gpc, which is unsupported. What file should I edit? I use suphp.

  6. #6
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Please post the full error from the log and which log you are seeing the error in specifically.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  7. #7
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    The error log is located at /usr/local/cpanel/logs/error_log . The message is the following, and there are several identical messages in the log, one after the other:

    <b>Fatal error</b>: Directive 'magic_quotes_gpc' is no longer available in PHP in <b>Unknown</b> on line <b>0</b><br />
    at /usr/local/cpanel/Cpanel/PHPINI.pm line 73
    Cpanel::PHPINI::check_installed_php_binaries() called at /usr/local/cpanel/Cpanel/PHPConfig.pm line 489
    Cpanel::PHPConfig::_get_partial_advconfig_conf() called at /usr/local/cpanel/Cpanel/PHPConfig.pm line 169
    Cpanel::PHPConfig::configure_php(HASH(0xa44d6d0)) called at /usr/local/cpanel/Cpanel/PHPConfig.pm line 143
    Cpanel::PHPConfig::setup_default_phpconf(HASH(0xa3ec01c)) called at /var/cpanel/perl/easy/Cpanel/Easy/Utils/PHP.pm line 232
    Cpanel::Easy::Utils::PHP::setup_php_include(Cpanel::Easy::Apache=HASH(0x9809e2c)) called at /var/cpanel/perl/easy/Cpanel/Easy/Uti$
    Cpanel::Easy::Utils::HttpdConf::_generate_config(Cpanel::Easy::Apache=HASH(0x9809e2c)) called at /var/cpanel/perl/easy/Cpanel/Eas$
    Cpanel::Easy::Utils::HttpdConf:ost_httpd_conf_handler(Cpanel::Easy::Apache=HASH(0x9809e2c)) called at /var/cpanel/perl/easy/Cpa$
    Cpanel::Easy::Apache::UI::HTML::cleanup(Cpanel::Easy::Apache::UI::HTML=HASH(0x9813814), Cpanel::Easy::Apache=HASH(0x9809e2c)) cal$
    Cpanel::Easy::cleanup(Cpanel::Easy::Apache=HASH(0x9809e2c)) called at /var/cpanel/perl/easy/Cpanel/Easy.pm line 1003
    Cpanel::Easy::install_profile(Cpanel::Easy::Apache=HASH(0x9809e2c), undef, undef) called at /var/cpanel/perl/easy/Cpanel/Easy/Apa$
    Cpanel::Easy::Apache::install_profile(Cpanel::Easy::Apache=HASH(0x9809e2c), undef) called at /var/cpanel/perl/easy/Cpanel/Easy/Ut$
    Cpanel::Easy::Utils::BackGround::__ANON__(Cpanel::Easy::Apache=HASH(0x9809e2c), undef, '/tmp/.cpanel_easy-.BftCymizO9TiUas5') cal$
    Acme::Spork::spork(CODE(0x9060628), Cpanel::Easy::Apache=HASH(0x9809e2c), undef, '/tmp/.cpanel_easy-.BftCymizO9TiUas5') called at$
    Cpanel::Easy::Utils::BackGround::run_install_in_bg(Cpanel::Easy::Apache=HASH(0x9809e2c), undef) called at /var/cpanel/perl/easy/C$
    Cpanel::Easy::Apache::UI::HTML::install_profile(Cpanel::Easy::Apache::UI::HTML=HASH(0x9813814), Cpanel::Easy::Apache=HASH(0x9809e$
    Cpanel::Easy::run(Cpanel::Easy::Apache=HASH(0x9809e2c)) called at /usr/local/cpanel/whostmgr/docroot/cgi/easyapache.pl line 81
    [2012-07-15 20:38:44 +0300] info [apache_conf_distiller] 'local' datastore in use (/var/cpanel/conf/apache/local)
    [2012-07-15 20:38:44 +0300] info [easyapache] 'local' datastore in use (/var/cpanel/conf/apache/local)
    [2012-07-15 20:38:55 +0300] warn [Cpanel::PHPINI] Unexpected output from /usr/bin/php -v : <br />

  8. #8
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    If you run "php -v" without the quotes in command line, does it show the same error or a different one?

    I'm right now trying to update my test machine to PHP 5.4 to see the results. That might take 30 minutes, so please stand by.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  9. #9
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    All right, so magic_quotes_gpc didn't compile on my machine with PHP 5.4, but it might be because I didn't previously have it selected. Please submit a ticket. I've just heard that if you select an MPM other than Prefork with PHP 5.4 that you might also have issues. We have an internal case about the magic quotes issue already (case 60278), but the ticket I've seen on the issue tried copying the PHP handler portion from another server's /usr/local/apache/conf/php.conf and that's not the ideal way to handle this. We'd need to see if we can get the handler to populate by possibly recompiling EasyApache to specifically remove magic quotes by using a custom build.

    A ticket can be submitted in WHM > Support Center > Contact cPanel or using the link in my signature. Please post the ticket number here afterward. I'm going to try to get to the ticket myself, since I'd like to investigate what is happening here (if it doesn't end up being magic quotes).
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  10. #10
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Hello, I submitted the ticket, the request ID is 2921678 .

  11. #11
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Of note, we found in the ticket that suhosin was the issue. EasyApache no longer allows PHP 5.4 + Suhosin to be compiled together. We have an internal case for /scripts/phpextensionmgr to prevent installation of suhosin there (that is case 2921678).
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  12. #12
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Doesn't this pose a security threat to the apache+php system, its compilation without suhosin?

  13. #13
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    How precisely can we add support for SuHosin with PHP 5.4 when SuHosin themselves do not yet support PHP 5.4?

    Whether it reduces security in any way, PHP 5.4 is labelled as experimental during EasyApache. These are the risks being taken by users when they select experimental options.

    Thanks!
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

  14. #14
    Member
    Join Date
    May 2010
    Posts
    10

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    I understand and agree, but I was just asking, could this pose a security threat, so that it would be advisable to defer upgrading to php 5.4 at this time? Is suhosin important, security-wise and in the context of php 5.4? Maybe php 5.4 contains some built-in security features?

  15. #15
    cPanel Staff cPanelTristan's Avatar
    Join Date
    Oct 2010
    Location
    somewhere over the rainbow
    Posts
    7,611
    cPanel/WHM Access Level

    Root Administrator

    Default Re: PHP Handler: None and Default PHP Version (.php files) is empty - PHP 5

    Unfortunately, I'm not aware of suhosin replacement options in PHP 5.4, although it's possible that these exist and I'm simply not finding any details. I believe the main reason it isn't yet compatible is that the developer of suhosin has been working on updating for PHP 5.4 for awhile and hasn't yet completed the process.
    cPResources: Support Options | More Support Options | Forums Search | cPanel.net Site Search | Mailing Lists(Alt) | Docs
    -- Tristan, Technical Analyst III, Forums Specialist, cPanel Tech Support

    Submit a ticket | Check an existing ticket

Page 1 of 2 12 LastLast

Similar Threads

  1. Individual php.ini files for PHP FCGI and PHP CGI
    By Miraenda in forum cPanel & WHM Discussions
    Replies: 10
    Last Post: 05-19-2013, 01:46 AM
  2. custom php.ini with php handler set as cgi
    By johny_gjx in forum cPanel & WHM Discussions
    Replies: 0
    Last Post: 02-16-2009, 03:54 AM
  3. PHP Version 4.4.2, register_globals ON php.ini no longer works!
    By sh4ka in forum cPanel & WHM Discussions
    Replies: 1
    Last Post: 06-02-2006, 04:06 PM
  4. PHP Update not working ( PHP version file is up to date )
    By ezztro in forum cPanel & WHM Discussions
    Replies: 8
    Last Post: 08-29-2005, 12:09 PM
  5. empty lines added into .php files
    By jifu in forum cPanel & WHM Discussions
    Replies: 2
    Last Post: 07-22-2003, 03:37 PM