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.

EasyApache 4 MultiPHP INI Editor values ignored

Discussion in 'EasyApache' started by kawasakai, Oct 19, 2015.

  1. kawasakai

    kawasakai Member

    Joined:
    Sep 17, 2015
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Germany
    cPanel Access Level:
    DataCenter Provider
    I have just upgraded from EA3 to EA4. When I now try to change some PHP Settings from the customer panel nothing happens. I tried for example to raise the memory_limit in the MultiPHP INI Editor, after that phpinfo still shows the default values.
    The php.ini file in the customers home location and public_html/ is created with the customized values: 'memory_limit = 64M'

    Nevertheless phpinfo shows the following:
    memory_limit:
    Code:
    32M 32M
    Configuration File (php.ini) Path:
    Code:
    /opt/cpanel/ea-php56/root/etc
    Additional .ini files parsed:
    Code:
    /opt/cpanel/ea-php56/root/etc/php.d/bcmath.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/calendar.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/ctype.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/curl.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/dom.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/ftp.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/gd.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/json.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/mcrypt.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/mysqlnd.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/mysqlnd_mysql.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/mysqlnd_mysqli.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/pdo.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/pdo_mysqlnd.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/pdo_sqlite.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/phar.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/posix.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/simplexml.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/sockets.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/sqlite3.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/tokenizer.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/xml.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/xml_wddx.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/xmlreader.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/xmlwriter.ini,
    /opt/cpanel/ea-php56/root/etc/php.d/xsl.ini
    
    As I noticed there is no value indicating to load ini files from the users home location.

    The .htaccsess file at public_html/ has the following content:
    Code:
    # BEGIN cPanel-generated handler, do not edit
    <IfModule mime_module>
      # Use ea-php56 as default
      AddType application/x-httpd-ea-php56 .php
    </IfModule>
    # END cPanel-generated handler
     
  2. cPJacob

    cPJacob cPanel Product Owner
    Staff Member

    Joined:
    May 2, 2014
    Messages:
    509
    Likes Received:
    65
    Trophy Points:
    28
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Hi,

    The INI editors are simply a file editor of sorts. There's nothing in the system that ensures that PHP actually uses this INI file, that is still left up to the system administrator and account owner. You'll need to setup the stack and htaccess files appropriately for having that PHP.ini read and used.
     
  3. kawasakai

    kawasakai Member

    Joined:
    Sep 17, 2015
    Messages:
    15
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Germany
    cPanel Access Level:
    DataCenter Provider
    Oh, okay thanks makes sense, I didn't know that this was intended :).
     
  4. Darren Cain

    Darren Cain Registered

    Joined:
    Sep 26, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    UK
    cPanel Access Level:
    Root Administrator
    How do we do that ? As I have the same problem, PHP.ini files being picked up in /opt/cpanel/ea-php56/root/etc/php.ini
    instead of local php.ini
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,814
    Likes Received:
    672
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  6. mcpacific

    mcpacific Member

    Joined:
    May 3, 2015
    Messages:
    11
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Los Angeles, CA
    cPanel Access Level:
    Root Administrator
    Has anyone figured this out?
     
  7. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,814
    Likes Received:
    672
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  8. Jason - Unlimited Net

    Joined:
    Oct 25, 2016
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    USA
    cPanel Access Level:
    DataCenter Provider
    Sorry to dig up an older thread, but I am also having issues with this and the links that @cPanelMichael provided are not helpful to me. We are using LiteSpeed Web Server, CloudLinux, CageFS, SuPHP and EA4. Custom php.ini files are being completely ignored within the user's home directory or DocumentRoot of their web site.

    Can anyone offer suggestions or tips? Running WHM 58.0 (build 32). Thank you!

    Best Regards,

    Jason
     
  9. nrm

    nrm Member
    PartnerNOC

    Joined:
    Jan 11, 2007
    Messages:
    16
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Moscow, Russia

    I have same trouble, open ticket 7832861 and that's what I know from cPanel support:


    So, do you using cagefs and/or do you edit php.ini via WHM MultiPHPEditor? That is the problem i guess...
     
  10. Jason - Unlimited Net

    Joined:
    Oct 25, 2016
    Messages:
    2
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    USA
    cPanel Access Level:
    DataCenter Provider
    Thank you, @nrm. I've tried disabling CageFS for the user I'm testing with and I also got rid of the local.ini file, but still no go. BuycPanel / cPanel has advised that it is a bug:

    - Jason
     
  11. Dean Morris

    Dean Morris Registered

    Joined:
    Oct 31, 2016
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Head in a rack
    cPanel Access Level:
    Root Administrator
    I got this as well, took me a bit to find out what the heck was going on.

    Is this really a bug? Should I report it in a ticket as well?
     
  12. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,814
    Likes Received:
    672
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello,

    Here's the information from our The cPanel PHPRC PHP Patch for EasyApache 4 - EasyApache 4 - cPanel Documentation document:

    Could you provide an example of a scenario where this is working differently to what's documented? Please provide specific step-by-step instructions on how to reproduce the issue, and include the PHP handler utilized by the account.

    Thank you.
     
  13. XxUnkn0wnxX

    XxUnkn0wnxX Member

    Joined:
    Feb 3, 2014
    Messages:
    19
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Website Owner
    could not get it to work even with this in my htaccess file with the php.ini in the directory i placed it in

    <IfModule mod_suphp.c>
    # Loads the module mod_suphp.c
    suPHP_ConfigPath /home/Admin/public_html
    # Specifies the path of the php.ini file. Use your legitimate path.
    <Files php.ini>
    # Specifies the file php.ini
    order allow,deny
    # This is ordering to check the allowed list first then the deny list.
    deny from all
    # Denies everyone from viewing the file specified above
    </Files>
    # Closes the files tag
    </IfModule>
    # Closes the modular line

    had to cd into /opt/cpanel/ea-php70/root/ete (since i'm on PHP 7)

    then mv php.ini php.ini.bak

    ln -sf /opt/cpanel/ea-php70/root/etc/php.d/local.ini /opt/cpanel/ea-php70/root/etc/php.ini

    now all changes made in local.ini are effective ;)

    but unsure what happens to the php.ini file in /opt/cpanel/ea-php70/root/etc/ when PHP is rebuilt or updated though, Why Doesn't Cpanel have an option to force use of custom directory for php.ini? For All Php Handlers & Versions, like an explicit Php.ini path that must be followed.
     
  14. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,814
    Likes Received:
    672
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello,

    The cPanel MultiPHP INI Editor will write to .user.ini files as well as php.ini files starting in cPanel version 62. This will help to alleviate problems where changes made via this interface don't take affect.

    Thank you.
     
Loading...

Share This Page