• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Resolved php plesk and memcache(d) extension

For example, depends on your OS it looks like:

# yum install php-pecl-memcache

After that check it with

# php -m | grep memcache
 
I suppose something like

# apt-get install php5-memcache
 
yes this for os version of PHP but not for plesk pack
You have to build the extension with PECL. Just download php5-dev packege of the matching version from http://autoinstall.plesk.com/PHP_5.5.27/ and do something like this:


# /opt/plesk/php/5.6/bin/pecl install memcached
# echo "extension=memcached.so" > /opt/plesk/php/5.6/etc/php.d/memcached.ini
# /opt/plesk/php/5.6/bin/php -i | grep "memcached support"
# memcached support => enabled
 
Hello, I've the issue and the details as below:

1. I've to build the extension with PECL. WITH MANY PACKAGE of DEBIAN 7.0 AND 8.0 , the result is Error: Unable to install the extension: The uploaded file is not a supported module package. Where is the true link ?

2. I've follow http://devblog.plesk.com/2015/08/adding-custom-php-modules-in-plesk/ and the results is

# yum search plesk-php devel
Warning: No matches found for: plesk-php
Warning: No matches found for: devel
No Matches found
# apt-get install memcached
Reading package lists... Done
Building dependency tree
Reading state information... Done
memcached is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
# apt-get install plesk-php56-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
plesk-php56-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
# /opt/plesk/php/5.6/bin
-bash: /opt/plesk/php/5.6/bin: Is a directory
# ./pecl install memcache
-bash: ./pecl: No such file or directory

My server information is - Debian 7.9 , Plesk v12.5.30

Please help

Thank you
 
Hi cookkoo,

1. I've to build the extension with PECL. WITH MANY PACKAGE of DEBIAN 7.0 AND 8.0 , the result is Error: Unable to install the extension: The uploaded file is not a supported module package. Where is the true link ?
Please explain WHAT you did, because your question is not really clear, what you mean or what you would like to know.


/opt/plesk/php/5.6/bin
-bash: /opt/plesk/php/5.6/bin: Is a directory
# ./pecl install memcache

Please note, that you devided the suggested command into TWO lines. Either move to the desired directory with the command "cd /opt/plesk/php/5.6/bin" and retry the command "./pecl install memcached", or use the whole command, as suggested: "/opt/plesk/php/5.6/bin/pecl install memcached"


yum search plesk-php devel
For Debian/Ubuntu - based systems, you would use the command:

apt-cache search plesk-php | grep dev

... to search for all possible plesk-php dev - packages.


The provided article from the "http://devblog.plesk.com/" was written for CentOS 7
The commands in the example are for CentOS 7, but you can make use of this functionality on different OSes as well. You may need to alter the package names slightly, but the underlying principle remains the same.
... so please consider to SEARCH for the OS - related packages for Debian with the apt-cache search option. I already did this for you, so you might use the following command to install all needed packages for Debian:

apt-get install make gcc libc6-dev libmemcached-dev zlib1g-dev

Please install the depending "plesk-phpNN-dev" - packages, which you found with apt-cache search and which you would like to work with on your server.
 
Hello UFHH01,

Thank you for your quick reply.
1. Please explain WHAT you did, because your question is not really clear, what you mean or what you would like to know.
Answer - php plesk and memcache(d) extention as it is the point of this topic :)

Others of your suggestion and your help, i will do it now. and will feedback ASAP. Thank you again.
 
Hello UFHH01,

# apt-get install make gcc libc6-dev libmemcached-dev zlib1g-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libc6-dev is already the newest version.
gcc is already the newest version.
make is already the newest version.
The following extra packages will be installed:
libhashkit-dev libhashkit2 libmemcachedprotocol0 libmemcachedutil2
libsasl2-dev
The following NEW packages will be installed:
libhashkit-dev libhashkit2 libmemcached-dev libmemcachedprotocol0
libmemcachedutil2 libsasl2-dev zlib1g-dev
0 upgraded, 7 newly installed, 0 to remove and 10 not upgraded.
Need to get 1,052 kB of archives.
After this operation, 2,719 kB of additional disk space will be used.
Do you want to continue [Y/n]? Y
Abort.

Please help
 
Hi cookkoo,

the message from your command line is pretty clear, isn't it? If you don't confirm the command with "Y" to continue, there won't be any needed installations and the process will be aborted.
 
Hello UFHH01,

1.
apt-get install make gcc libc6-dev libmemcached-dev zlib1g-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
libc6-dev is already the newest version.
gcc is already the newest version.
make is already the newest version.
The following extra packages will be installed:
libhashkit-dev libhashkit2 libmemcachedprotocol0 libmemcachedutil2
libsasl2-dev
The following NEW packages will be installed:
libhashkit-dev libhashkit2 libmemcached-dev libmemcachedprotocol0
libmemcachedutil2 libsasl2-dev zlib1g-dev
0 upgraded, 7 newly installed, 0 to remove and 10 not upgraded.
Need to get 1,052 kB of archives.
After this operation, 2,719 kB of additional disk space will be used.
Do you want to continue [Y/n]?
Get:1 http://mirror.hetzner.de/debian/packages/ wheezy/main libhashkit2 amd64 1.0.8-1 [36.8 kB]
Get:2 http://mirror.hetzner.de/debian/packages/ wheezy/main libmemcachedprotocol0 amd64 1.0.8-1 [29.7 kB]
Get:3 http://mirror.hetzner.de/debian/packages/ wheezy/main libmemcachedutil2 amd64 1.0.8-1 [22.5 kB]
Get:4 http://mirror.hetzner.de/debian/packages/ wheezy/main libhashkit-dev amd64 1.0.8-1 [55.8 kB]
Get:5 http://mirror.hetzner.de/debian/packages/ wheezy/main libsasl2-dev amd64 2.1.25.dfsg1-6+deb7u1 [360 kB]
Get:6 http://mirror.hetzner.de/debian/packages/ wheezy/main libmemcached-dev amd64 1.0.8-1 [332 kB]
Get:7 http://mirror.hetzner.de/debian/packages/ wheezy/main zlib1g-dev amd64 1:1.2.7.dfsg-13 [215 kB]
Fetched 1,052 kB in 0s (7,270 kB/s)
Selecting previously unselected package libhashkit2:amd64.
(Reading database ... 117047 files and directories currently installed.)
Unpacking libhashkit2:amd64 (from .../libhashkit2_1.0.8-1_amd64.deb) ...
Selecting previously unselected package libmemcachedprotocol0:amd64.
Unpacking libmemcachedprotocol0:amd64 (from .../libmemcachedprotocol0_1.0.8-1_amd64.deb) ...
Selecting previously unselected package libmemcachedutil2:amd64.
Unpacking libmemcachedutil2:amd64 (from .../libmemcachedutil2_1.0.8-1_amd64.deb) ...
Selecting previously unselected package libhashkit-dev.
Unpacking libhashkit-dev (from .../libhashkit-dev_1.0.8-1_amd64.deb) ...
Selecting previously unselected package libsasl2-dev.
Unpacking libsasl2-dev (from .../libsasl2-dev_2.1.25.dfsg1-6+deb7u1_amd64.deb) ...
Selecting previously unselected package libmemcached-dev.
Unpacking libmemcached-dev (from .../libmemcached-dev_1.0.8-1_amd64.deb) ...
Selecting previously unselected package zlib1g-dev:amd64.
Unpacking zlib1g-dev:amd64 (from .../zlib1g-dev_1%3a1.2.7.dfsg-13_amd64.deb) ...
Processing triggers for man-db ...
Setting up libhashkit2:amd64 (1.0.8-1) ...
Setting up libmemcachedprotocol0:amd64 (1.0.8-1) ...
Setting up libmemcachedutil2:amd64 (1.0.8-1) ...
Setting up libhashkit-dev (1.0.8-1) ...
Setting up libsasl2-dev (2.1.25.dfsg1-6+deb7u1) ...
Setting up libmemcached-dev (1.0.8-1) ...
Setting up zlib1g-dev:amd64 (1:1.2.7.dfsg-13) ...
root@cookkoo ~ #

This is mean successful to installed , correct ?

2.
If yes, TO Config Increase Max Memory memcache from this link https://rtcamp.com/tutorials/php/memcache/ , Is it necessary to do it or not?
Because the structure system of the server not the same.

Please help to suggestion.

Thank you
 
Hello again UFHH01,

For more information. I can not see memcached enable on cookkoo.com/phpinfo.php and at my wordpress backend , memcached option in W3 Total Cache it can not choose to work. Please help
 
Hi cookkoo,

such a suggestion from rtcamp really depends on various factors. You don't provide informations about your hardware on your server. How much memory is used on your server on average?

I would suggest to leave out any further tweaks, untill you recognize issues / failures / problems, or if you experince poor response times from your server.
 
Hello, I have a problem... Please help me. I´m using a hosting web parallels plesk panel 10.4 and I install wordpress, but I have a problem when I like to up a .zip archive because request to 5.3 php version and my web hosting don´t give me other version more high that 5.2.17. How can i get a solution? Please
 

Attachments

  • error.png
    error.png
    50.6 KB · Views: 7
Hello UFHH01,

1. I've changed PHP Setting from 5.5 to 5.6.15 as explain in http://devblog.plesk.com/2015/08/adding-custom-php-modules-in-plesk/ , but can not see "memcached".

2. About a suggestion from rtcamp as we said above. From my content, now i have more than 2 million users with 28 GB of database not included with images on web server. And if the web site is work fine after trying to configuration as you help to do now. i must to import the users to 18 million users. All of them will to be 5.6 TB of database + web server.

3. As you said above "I would suggest to leave out any further tweaks, untill you recognize issues / failures / problems, or if you experince poor response times from your server."
Now the response time and the performance not so good. and i wish to tweak for best performance, and my server information as below:
- Dedicated Server , LAMP installed (have plan to run nginx as reverse proxy as why i choose plesk to be control panel for the best config)
- Intel® Core™ i7-3770 Quad-Core incl. Hyper-Threading Technology
- RAM 32 GB DDR3 RAM
- Hard Drive 4 x 6 TBx 6 TB SATA 3 GB/S 7200 rpm HDD Software-Raid

Please help

Thank you
 
Hi cookkoo,

1. I've changed PHP Setting from 5.5 to 5.6.15 as explain in http://devblog.plesk.com/2015/08/adding-custom-php-modules-in-plesk/ , but can not see "memcached".

Well, you didn't change the PHP version for your domain. You still use PHP Version 5.5.30, which you can see at your phpinfo.

Home > Subscriptions > cookkoo.com > Websites & Domains > PHP Settings

You didn't answer the question, if you actually SEE "memcached" at "Tools & Settings > PHP Settings" ?!?

memcached.png
You didn't answer the question, if you FOLLOWED the rest of the article, as for example:
...
Then we build the module:

/opt/plesk/php/5.6/bin/pecl install memcached
(when prompted for the libmemcached directory, leave it blank and hit the Enter key)

And register it with Plesk:
echo "extension=memcached.so" > /opt/plesk/php/5.6/etc/php.d/memcached.ini

plesk bin php_handler --reread
...



With your hardware, there is nothing wrong to raise the memcached configuration value from 64 to 1024.
 
Back
Top