Add PHP shmop extension support useful for Wordpress performance and site health
When you run the Wordpress Helath Check under Wordpress Tools menù and you run a Plesk server you will get the following alert:
You should allow inter-process communication Performance
You should consider using shared memory (PHP shmop) to allow inter-process communication.
Could I suggest to add the PHP shmop support?
I'm running PHP 8.3 and I'm not sure to use SSH command to try to get this extension working, will be nice if in the future this can be integrated in Plesk as ... today Wordpress is a very used CMS and we want always to have good performance.
Thank you!
Thank you for your idea! We will consider this functionality in upcoming releases if it will be popular.
Everyone, please continue voting for this feature if you consider it important.
Meanwhile, if you want to try to install shmop yourself, these are the general steps (provided here without warranty, try it on a test server before applying it to your production system):
1) Install Plesk PHP development package:
For RPM-based OS (CentOS, RHEL, CloudLinux):
# yum install plesk-php83-devel
For Debian-based OS (Debian, Ubuntu):
# apt install plesk-php83-dev build-essential
2) Check what's the currrent version of your PHP 8.0
# /opt/plesk/php/8.3/bin/php -v
3) Download PHP source based on the version of the step 2
For example:
# wget https://www.php.net/distributions/php-8.3.0.tar.bz2
Please pay special attention that the version matches the one determined in step 2!
4) Extract the .tar file of the PHP downloaded
# tar -xvjf /root/php-8.3.0.tar.bz2
Again, the version shown here is just an example. You have determined the correct version in step 2.
5) Go to shmop extension location:
# cd /root/php-8.3.0/ext/shmop
6) Run phpize:
# /opt/plesk/php/8.3/bin/phpize
7) Run configure:
# ./configure --with-php-config=/opt/plesk/php/8.3/bin/php-config
8) Build and install extension:
# make && make install
9) Load extension to the PHP 8.3 installed with Plesk
# echo "extension=shmop.so" >> /opt/plesk/php/8.3/etc/php.d/shmop.ini
10) Ensure that the extension is loaded in the command line or via the PHPinfo page at Domains > example.com > PHP Settings
# /opt/plesk/php/8.3/bin/php -m | grep shmop
-- PD
-
Marco B commented
Thank you!
Instruction on how to solve the Wordpress performance issue in site health so how to have this extension installed on Plesk was my curiosity.
Thanks for the steps. I need have a testing server to test this, unfortunately I'm in a prod server.. but have instructions is good.I really hope you can in future provide an extension that Wordpress site heath suggest to install to improve Wordpress performance.
Thanks again!I hope users will vote this.