How to enable Apache PHP module for a domain?

Follow

Comments

2 comments

  • Avatar
    Keith Arnold

    Hi,

    Is there another article on how to Enable mod_php5 as the linked article is not available. I get:

    oops

    You're not authorized to access this page

    Regards
    Keith

    0
    Comment actions Permalink
  • Avatar
    Ivan Postnikov (Edited )

    Hello @Keith!

    Thank you for noticing.

    Indeed, that other article is currently unavailable, it is being reviewed to be more helpful.

     

    I will post the required steps here but be adviced that this steps are done at your own risk and enabling the Apache handler mod_php is not safe as it is outdated and insecure. Use PHP in FastCGI or FPM mode instead.

    1. In Plesk, go to Tools & Settings > Apache Web Server:

      1.1. Change the MPM mode to Prefork.

      1.2. Click Apply.

      1.3. Enable the 'php5' module.

      1.4. Click OK.

      • Additionally on Debian/Ubuntu-based distributions, connect to a Plesk server via SSH and apply the following commands additionally:

        touch /var/lib/apache2/module/disabled_by_admin/mpm_event
        # touch /var/lib/apache2/module/enabled_by_admin/mpm_prefork
        # touch /var/lib/apache2/module/enabled_by_admin/php5

    2. Then, go to Tools & Settings > PHP Settings. and enable the Apache mod_php handler.

    3. To set the Apache mod_php handler for a domain, go to Domains > example.com > PHP Settings: Select PHP version by OS vendor and run PHP as mod_php.

    Only steps 2 and 3 may be sufficient for Plesk Onyx

    0
    Comment actions Permalink

Please sign in to leave a comment.

Have more questions? Submit a request