0

I am transferring a PHP application 9running on apache) from Centos to Ubuntu. When I deploy the code on Ubuntu I get an error "Class Libmemcached not found".

When I compare phpinfo pages, I can see that the Centos one has "libmemcached" section, while the Ubuntu one has "memcached" section.

On both systems phpinfo has "memcache" (no "d" in the end) section.

It looks like my Centos PHP has "libmemcached" extension and my Ubuntu PHP doesn't. How can I download that extension? Or can I somehow just transfer the extension from my Centos system?

I found php-libmemcached repository on github ( https://github.com/kajidai/php-libmemcached ), that might be what I am looking for, but I don't know how to install it on Ubuntu.

Please help.

1 Answers1

0

The libmemcached extension you are using isn't an official extension. I don't know were Centos get it from.

So I recommend to use/install the official memcached extension from PECL and update your application.

Else you have to install the libmemcached extension from scratch with the following steps:

  • download from github
  • unpack the file
  • go into the new folder
  • phpize
  • ./configure
  • make install
  • enable it within you php.ini
  • restart you webserver
mabe.berlin
  • 1,043
  • 7
  • 22