Since this is NPR better to keep it internal
Applicable to:
- Plesk for Linux
Question
How to install APCu PHP module for Plesk PHP?
Answer
Warning: APCu is not officially supported by Plesk and was not tested extensively. Use the instructions below at your own risk.
-
Connect to the server via SSH.
-
Install required development packages:
-
For .deb-based OS (Ubuntu, Debian):
# apt install plesk-php80-dev zlib1g-dev gcc make
-
For .rpm-based OS (CentOS, RHEL, CloudLinux):
# yum install plesk-php80-devel zlib-devel gcc make
Note: As an example, Plesk PHP 7.0 development package is installed. For a different version of PHP change
php80
to the required version, for instance,php70
,php56
-
-
Install the APCu PHP module:
-
For Plesk PHP 5.x:
# /opt/plesk/php/5.x/bin/pecl install apcu-4.0.11
-
For Plesk PHP 7.x::
# /opt/plesk/php/7.x/bin/pecl install apcu
-
-
- For Plesk PHP 8.x
# /opt/plesk/php/8.x/bin/pecl install apcu
- For Plesk PHP 8.x
-
Enable APCu in PHP configuration:
# echo "extension=apcu.so" > /opt/plesk/php/8.0/etc/php.d/apcu.ini
-
Restart PHP service and refresh PHP handlers information:
# service plesk-php80-fpm restart
# plesk bin php_handler --reread
-
Verify that the module is loaded and is working:
# /opt/plesk/php/8.0/bin/php -i | grep apc.enabled
apc.enabled => On => OnTo check whether APCu is enabled, open the php_info() page and find the following content:
Comments
0 comments
Please sign in to leave a comment.