Join the community today
Become a Member

Memcached Best Module: Memcached or Memcache Pecl?

Discussion in 'Other Centmin Mod Installed software' started by rdan, Jun 7, 2016.

  1. rdan

    rdan Premium Member Premium Member

    4,225
    1,027
    113
    May 25, 2014
    Ratings:
    +1,467
    Local Time:
    6:25 AM
    Mainline
    10.2
    Which one performs better?

    I got 2 options from wordpress plugin directory.

    One that support Memcached and Memcache pecl but outdated plugin (last update 1 year ago / not tested with latest WP version).
    and other one that is actively developed/updated plugin which is also mostly recommended plugin but only support Memcache pecl module.
     
  2. eva2000

    eva2000 Administrator Staff Member

    35,072
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    8:25 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    memcached PHP extension if you can
     
  3. rdan

    rdan Premium Member Premium Member

    4,225
    1,027
    113
    May 25, 2014
    Ratings:
    +1,467
    Local Time:
    6:25 AM
    Mainline
    10.2
    Why is that? :)
    Thanks!
     
  4. eva2000

    eva2000 Administrator Staff Member

    35,072
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    8:25 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    newer and more up to date
     
    • Like Like x 1
  5. rdan

    rdan Premium Member Premium Member

    4,225
    1,027
    113
    May 25, 2014
    Ratings:
    +1,467
    Local Time:
    6:25 AM
    Mainline
    10.2
    For PHP 7, I have this version:
    upload_2016-6-7_14-16-43.png
     
  6. Revenge

    Revenge Active Member

    401
    84
    28
    Feb 21, 2016
    Portugal
    Ratings:
    +299
    Local Time:
    11:25 PM
    1.9.x
    10.1.x
    I use this one:
    Code:
    Installed Packages
    Name        : php-pecl-memcached
    Arch        : x86_64
    Version     : 3.0.0
    Release     : 0.1.20160217git6ace07d.el7.remi.7.0
    Size        : 244 k
    Repo        : installed
    From repo   : remi-php70
    Summary     : Extension to work with the Memcached caching daemon
    URL         : http://pecl.php.net/package/memcached
    License     : PHP
    Description : This extension uses libmemcached library to provide API for communicating
                : with memcached servers.
                :
                : memcached is a high-performance, distributed memory object caching system,
                : generic in nature, but intended for use in speeding up dynamic web
                : applications by alleviating database load.
                :
                : It also provides a session handler (memcached).
                :
                : Package built for PHP 7.0.
     
    • Like Like x 1
  7. rdan

    rdan Premium Member Premium Member

    4,225
    1,027
    113
    May 25, 2014
    Ratings:
    +1,467
    Local Time:
    6:25 AM
    Mainline
    10.2
    But on PECL site it only have version 2.2.0: PECL :: Package :: memcached
     
  8. Revenge

    Revenge Active Member

    401
    84
    28
    Feb 21, 2016
    Portugal
    Ratings:
    +299
    Local Time:
    11:25 PM
    1.9.x
    10.1.x
    I installed it from the Remi Repo.
     
    • Like Like x 1
  9. eva2000

    eva2000 Administrator Staff Member

    35,072
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    8:25 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    that's because Centmin Mod uses latest dev version of memcache PHP extension from an unofficial git repo branch specific for PHP 7 support :) Probably same source where Remi repo one came from ?
     
  10. Revenge

    Revenge Active Member

    401
    84
    28
    Feb 21, 2016
    Portugal
    Ratings:
    +299
    Local Time:
    11:25 PM
    1.9.x
    10.1.x
    Remi uses the php-memcached, that one is php-memcache. Two different extensions.
     
  11. eva2000

    eva2000 Administrator Staff Member

    35,072
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    8:25 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    oh yes.. both memcached and memcache on Centmin Mod are PHP 7 supported as i use unofficial/not main github repo branches - so that's what I am suggestion Remi repo has done too :)

     
  12. jeffwidman

    jeffwidman Active Member

    152
    27
    28
    Dec 3, 2014
    Ratings:
    +51
    Local Time:
    3:25 PM
    On one of the forums I admin, I recently upgraded the server to PHP7 and now seeing a lot of these errors:

    XF 1.4 - Registration problem. "The field 'xxxxxxxx' was not recognised." | XenForo Community

    Thanks to @RoldanLT for debugging that it's most likely a memcache issue.

    Currently I have the following for the xenforo config.php on that site:
    Code:
    $config['cache']['enabled'] = true;
    $config['cache']['frontend'] = 'Core';
    $config['cache']['cacheSessions'] = true;
    $config['cache']['frontendOptions'] = array(
            'caching' => true,
            'cache_id_prefix' => 'mvc_xf_',
            'automatic_serialization' => true,
            'lifetime' => 0
          );
    
    $config['cache']['backend'] = 'Libmemcached';
    $config['cache']['backendOptions'] = array(
            'servers' => array(
                array(
                    'host' => '127.0.0.1',
                    'port' => 11211,
                    'persistent' => 'true',
                    'weight' => 1
                )
            )
      );
    
    @RoldanLT what memcache PHP library are you using on your PHP 7 box?

    @eva2000 should I switch to using memcached rather than libmemcached since this is a PHP7 box? I saw your note above about memcached being based on libmemcached, not sure though if that means I need to use memcached rather than libmemcached or not.
     
  13. eva2000

    eva2000 Administrator Staff Member

    35,072
    7,742
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +11,941
    Local Time:
    8:25 AM
    Nginx 1.15.x
    MariaDB 5.5/10.x
    memcached php extension uses libmemcached, so that is correct

    but xenforo 1.4 doesn't fully support php 7. For php 7 you need to be using xenforo 1.5 branch.
     
  14. rdan

    rdan Premium Member Premium Member

    4,225
    1,027
    113
    May 25, 2014
    Ratings:
    +1,467
    Local Time:
    6:25 AM
    Mainline
    10.2
    Not anymore, I'm using Redis Caching now.
     
..