How to Change PHP-FPM SettingsAugust 23, 2016

In this KB:

  • How to Change PHP Settings
  • Examples of PHP directives
  • Important notes

 

This support article will guide you on how to change your PHP related settings for FPM enabled servers using PHP Settings editor. 

Step 1: Go to Application Management

Click on “Applications” on the top menu bar and then select your target application from the list.

Application Management

Step 2: Configure PHP-FPM Settings

You can manage PHP related settings and directives by using PHP settings editor. This can be accessed from the console in “PHP Settings” tab of “Application Settings” under the Application Management page as follows.

Note: Please use this editor carefully and enter values in the proper format. There is a risk you may break your application(s) with incorrect settings.

PHP Settings

Examples of PHP directives

The following are a few examples of PHP directives (per application settings) for PHP-FPM enabled servers.

1) Editing the Post Max Size

2) Setting Max Input Time

3) Setting Max Execution Time

4) Setting Memory Limit

5) Editing the Upload Max File Size

6) Setting Display Errors

 

Important Notes:

  • Any PHP directives defined in a .htaccess will not be used. You can use the PHP settings as defined in Step 2.
  • It is important to comment rules that you have set in the htaccess file for PHP directives (commands starting with php_value or php_flag etc.). Otherwise, you’ll see an “internal server error” message or a blank page.
  • Non FPM servers (those deployed before August 23, 2016) will continue to use .htaccess for PHP settings in each application.
  • The rewrite/redirect rules defined in a .htaccess file will be effective for both environments.
  • For server level PHP settings (e.g. execution limit, max input variables, max input time etc.), use the Server Settings option.

4 Responses

  1. Marijn Achterkamp says:

    Will the normal htaccess redirect keep working with FPM?

  2. Mitch says:

    This might go wrong:
    php_value[php_post_max_size] = 25M

    Instead, use this::
    php_value[post_max_size] = 25M

Leave a Reply

Still need help? Our support team is waiting to help you. Ask them now