Does memcached support replication with fail over?. In some posts I've read they mentioned that there is no connection between the nodes and they are blind, but in some they are talking about replication.
Memcache cluster failover replication
3.1k views Asked by Aruna Karunarathna At
2
There are 2 answers
1
On
it should be pointed out that newer versions of memcached do support replication. Options:
- MEMCACHED_BEHAVIOR_NUMBER_OF_REPLICAS
- session_number_of_replicas
can both be investigated.
session_number_of_replicas can be used with sess_binary=1 and sess_consistent_hash=1 to repicate sessions over memcached nodes.
MEMCACHED_BEHAVIOR_NUMBER_OF_REPLICAS in conjunction with MEMCACHED_BEHAVIOR_REMOVE_FAILED_SERVERS can be used to create cache persistence (not to be confused with data persistence as it is still cache) with failover.
No. Memcache does not support replication or persistence. Also its true that there is no connection between the nodes. And this simplicity is the reason that it is one of the fastest caches.
It is usually the client that handles multiple nodes and decides which key belongs to which server.
There are some patches available to enable replication on memcache. You can take a look at Repcached