Hi,
I’ve installed memcache but i can’t see the module inside the php option on Webmin.
If i check with ssh: php -m i see the module.
How can i enable on Webmin ?
Thanks
SYSTEM INFORMATION
OS type and version:
CentOS Linux 7.9.2009
Webmin version:
1.984
Ilia
January 21, 2022, 11:08am
2
Hello,
There is no need to enable it on Webmin side, as it’s already enabled.
Check for the following files (those enable your PHP memcached extension):
/etc/php.d/igbinary.ini
/etc/php.d/msgpack.ini
/etc/php.d/z-memcached.ini
Hi,
All extensions are enabled.
i’ve created a file php
<?php
phpinfo();
?>
But the module isn’t enabled inside the list.
Ilia
January 21, 2022, 11:24am
6
That means you have multiple PHP versions installed. You must install memcached extension for the PHP version that is currently used for your virtual server.
This is easier checked using Virtualmin / Server Configuration ⇾ PHP Options page.
I’ve PHP 7.2 and 7.3 installed.
Ilia
January 21, 2022, 11:34am
8
Then install PHP memcached
for the PHP version used for the virtual server or install for all by running something like:
yum install php*-memcached
No package php73-memcached available.
Ilia
January 21, 2022, 11:42am
10
What about php73-php-pecl-memcached
package?
Package php73-php-pecl-memcached-3.1.5-1.el7.remi.x86_64 already installed and latest version
Ilia
January 21, 2022, 11:47am
12
Try reinstalling it.
yum reinstall php73-php-pecl-memcached
Again double check that it’s loaded in /etc/opt/remi/php73/php.d/50-memcached.ini
file.
i can’t find this path /etc/opt/remi/php73/php.d/50-memcached.ini
Ilia
January 21, 2022, 10:29pm
14
It should be there in PHP 7.3 provided by remi-safe repos.
What is the output of:
find /etc -name "*memcached*"
Try reinstalling the package as suggested earlier.
yum reinstall php73-php-pecl-memcached
It’s expected that given virtual server is using PHP 7.3.
Check this manual on installing additional PHP versions:
https://www.virtualmin.com/documentation/web/multiplephp/
With
find /etc -name "*memcached*"
/etc/php.d/50-memcached.ini
/etc/php-zts.d/50-memcached.ini
/etc/opt/remi/php73/php.d/50-memcached.ini
/etc/selinux/targeted/tmp/modules/100/memcached
/etc/selinux/targeted/active/modules/100/memcached
/etc/sysconfig/memcached
/etc/systemd/system/multi-user.target.wants/memcached.service
And of course the virtual server is using PHP 7.3.
Thanks
Ilia
January 22, 2022, 8:56am
16
The file seems to be there. I am pretty sure that it must work. It works for me.
Wait, did you by any chance forgotten to restart Apache or PHP-FPM?
Depending on execution mode you need to restart either php73-php-fpm.service
process or httd.service
.
Try running:
systemctl restart php73-php-fpm.service
systemctl restart httpd.service
I’ve restarted Apache many times.
Modules for PHP 7.3
bz2
calendar
cgi-fcgi
Core
ctype
curl
—
—
—
—
—
—
date
dom
exif
fileinfo
filter
ftp
gd
gettext
hash
iconv
imagick
intl
json
libxml
mbstring
mysqli
mysqlnd
openssl
pcntl
pcre
PDO
pdo_mysql
pdo_sqlite
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
SPL
sqlite3
ssh2
standard
sysvmsg
sysvsem
sysvshm
tokenizer
wddx
xml
xmlreader
xmlwriter
xsl
zip
zlib
Ilia
January 22, 2022, 9:12am
18
Where do you see this table? Can I see the link to phpinfo();
output?
I’ll send you a message with the url.
Thanks
Ilia
January 22, 2022, 6:20pm
20
Have you somehow managed to install PHP from both SCL and Remi repos? If so, make sure that you don’t have the same versions installed at the same time.
Anyway, I now see that your virtual server is currently using rh-php73
in FastCGI mode. The solution to your problem would be as simple as running the following commands:
yum install sclo-php73-php-pecl-memcached
systemctl restart httpd
1 Like