Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

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.

Incorrect behavior of the .yaml file editing process for FPM

Discussion in 'EasyApache' started by speckados, Sep 6, 2017.

Tags:
  1. speckados

    speckados Well-Known Member

    Joined:
    May 21, 2003
    Messages:
    305
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Acequias :: Granada :: España
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Hi.

    I use personalized configurations for some user and like limit max memory tags.

    Best way it's edit file
    Code:
     /var/cpanel/userdata/[user]/[domain].php-fpm.yaml 
    and after run

    Code:
    /scripts/php_fpm_config --rebuild
    This wor for too many flags of php, but woth memory_limit not work.


    Example-->
    Edit /var/cpanel/userdata/[user]/[domain].php-fpm.yaml

    Code:
    ---
    _is_present: 1
    php_admin_value_memory_limit: 1G
    php_admin_value_short_open_tag : off
    
    After run rebuild fpm config
    Code:
    php_admin_value_memory_limit = 1G  // Incorrect line for fpm config and crash server
    php_admin_value[short_open_tag] = off
    PHP-FPM Code and FileSystem Layout for EasyApache 4 - Documentation - cPanel Documentation

    What is wrong?
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,165
    Likes Received:
    1,371
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    Can you try using 1024M instead of 1G to see if that works?

    Thank you.
     
  3. speckados

    speckados Well-Known Member

    Joined:
    May 21, 2003
    Messages:
    305
    Likes Received:
    0
    Trophy Points:
    166
    Location:
    Acequias :: Granada :: España
    cPanel Access Level:
    DataCenter Provider
    Twitter:
    Hi.

    Same prblem.

    But logic of programing its a bad method for convert php_admin_value_memory_limit onto php_admin_value[memory_limit].

    Best regards,


    Code:
    ● ea-php56-php-fpm.service - The PHP FastCGI Process Manager
       Loaded: loaded (/usr/lib/systemd/system/ea-php56-php-fpm.service; enabled; vendor preset: disabled)
       Active: failed (Result: exit-code) since Wed 2017-09-06 20:05:46 CEST; 5s ago
      Process: 27220 ExecStart=/opt/cpanel/ea-php56/root/usr/sbin/php-fpm --nodaemonize (code=exited, status=78)
     Main PID: 27220 (code=exited, status=78)
    
    Sep 06 20:05:46 srv105.tamainut.net systemd[1]: Starting The PHP FastCGI Process Manager...
    Sep 06 20:05:46 srv105.tamainut.net php-fpm[27220]: [06-Sep-2017 20:05:46] ERROR: [/opt/cpanel/ea-php56/root/etc/php-fpm.d/lavermuteria.com.conf:21] unknown entry 'php_admin_value_memory_limit'
    Sep 06 20:05:46 srv105.tamainut.net php-fpm[27220]: [06-Sep-2017 20:05:46] ERROR: Unable to include /opt/cpanel/ea-php56/root/etc/php-fpm.d/lavermuteria.com.conf from /opt/cpanel/ea-php56/root/etc/php-fpm.conf at line 21
    Sep 06 20:05:46 srv105.tamainut.net php-fpm[27220]: [06-Sep-2017 20:05:46] ERROR: failed to load configuration file '/opt/cpanel/ea-php56/root/etc/php-fpm.conf'
    Sep 06 20:05:46 srv105.tamainut.net php-fpm[27220]: [06-Sep-2017 20:05:46] ERROR: FPM initialization failed
    Sep 06 20:05:46 srv105.tamainut.net systemd[1]: ea-php56-php-fpm.service: main process exited, code=exited, status=78/n/a
    Sep 06 20:05:46 srv105.tamainut.net systemd[1]: Failed to start The PHP FastCGI Process Manager.
    Sep 06 20:05:46 srv105.tamainut.net systemd[1]: Unit ea-php56-php-fpm.service entered failed state.
    Sep 06 20:05:46 srv105.tamainut.net systemd[1]: ea-php56-php-fpm.service failed.
     
  4. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    38,165
    Likes Received:
    1,371
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    This should be updated to match the examples we provide at:

    Configurations Values of PHP-FPM - Documentation - cPanel Documentation

    EX:

    Code:
    ---
    _is_present: 1
    php_admin_value_memory_limit: { name: 'php_admin_value[memory_limit]', value:1024M }
    Can you verify if any issues persist when updating the entries to match this format?

    Thank you.
     
Loading...

Share This Page