Information zur Installation dieser PECL-Extension finden sie im Kapitel Installation von PECL-Extensions. Zus√§tzliche Informationen wie neue Releases, Downloads, Quelldateien, Maintainerinformation und ein CHANGELOG finden Sie hier: »

If libmemcached is installed in a non-standard location, use --with-libmemcached-dir=DIR switch, where DIR is the libmemcached install prefix. This directory has to contain the include/libmemcached/memcached.h file.

Zlib is required for compression support. To specify non-standard installation of Zlib, use --with-zlib-dir=DIR switch, where DIR is the Zlib install prefix.

Session handler support is enabled by default. To disable it, use --disable-memcached-session switch.

SASL authentication support is disabled by default. To enable it, use --enable-memcached-sasl switch. This requires that libsasl2 has been installed and that libmemcached has been built with SASL support enabled.

add a note add a note

User Contributed Notes 4 notes

qeremy [at] gmail [dot] com
2 years ago
Do not lose your time to install it on Ubuntu just trying "sudo apt-get install php5-memcached". There is something you need to do that sure installing memcached. Anyway...

Step 1.
$ sudo apt-get install memcached
Step 2.
$ sudo apt-get install php5-memcached
Step 3.
$ sudo /etc/init.d/apache2 restart


What about some test?


$mc = new Memcached();
$mc->addServer("localhost", 11211);

$mc->set("foo", "Hello!");
$mc->set("bar", "Memcached...");

$arr = array(

Hoping to help someone.
petermiller1986 att gmail dotttttttt com
2 years ago
i'm planning on using membase for my website and i was really struggling to install the memcashed php client on ubuntu with pear, but actually there is an easier way:

$ sudo apt-get install php5-memcached

you dont even need to install the membase server first - this can be done afterwards. hope this helps someone!
gpuk at dasserver dot com
4 years ago
At present memcached-1.0.0 does not compile with libmemcached-0.38. This is apparently due to libmemcached chaning the API.

For evidence, see this bug:

Note: I am encountering the same 'memcached_st' has no member named 'hash' error on a Debian lenny amd_64 box.
Clint Priest
4 years ago
If your server has --enable-json=shared as mine did, this extension requires you to have to load properly.
To Top