memcached not found but installed

January 13, 2015 1k views
  • Somewhere in your php.ini file are two entries.

    log_errors = On
    error_log = syslog

    For error_log, I think you can also provide a file (let's say '/var/log/php_errors.log') that your web server can write to.

    After restarting your web server, try the memcached test again (from the tutorial) and look for any errors that pop up in that logfile.

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

    Post your log errors, if any, and someone here might be able to further diagnose.

  • Class 'Memcached' not found

  • @zsoltgyure96 - On fedora I installed the package php-pecl-memcached to work with memcache, and I monitor by using phpMemcachedAdmin. I don't know the equivalent on Debian. Sorry.

  • @zsoltgyure96 - I spun up a new droplet (Ubuntu LEMP 14.04) to step through the tutorial, and it worked as advertised.

    Your imgur image of the phpinfo() output didn't show the 'memcached' section of the version number for memcached and libmemcached, as well as some memcached directives? Do you have that section? If not, then something went wrong with the apt-get of the required components.

Be the first one to answer this question.