Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Minimize Loadable PHP Modules (Dynamic Extensions)  (Read 1929 times)

0 Members and 1 Guest are viewing this topic.

Aby

  • Guest
Minimize Loadable PHP Modules (Dynamic Extensions)
« on: April 22, 2014, 10:32:50 pm »
Minimize Loadable PHP Modules (Dynamic Extensions)

PHP supports "Dynamic Extensions". By default, RHEL loads all the extension modules found in /etc/php.d/ directory. To enable or disable a particular module, just find the configuration file in /etc/php.d/ directory and comment the module name. You can also rename or delete module configuration file. For best PHP performance and security, you should only enable the extensions your webapps requires.

For example, to disable gd extension, type the following commands:
Code: [Select]
# cd /etc/php.d/
# mv gd.{ini,disable}
# /sbin/service httpd restart

To enable php module called gd, enter:

Code: [Select]
# mv gd.{disable,ini}
# /sbin/service httpd restart

-----