Memcached One of building cluster analysis

Source: Internet
Author: User

Memcached itself is not support cluster, cluster concern of disaster tolerance, fault-tolerant, downtime recovery mechanism all have no, actual combat need to implement disaster tolerance mechanism.

The advantages of the memcached cluster compared to memcached:

The huge amount of data distributed to multiple application hosts in the cluster can reduce bandwidth pressure and data access time.

memcached clusters have advantages over multiple memcached that are not clustered:

The disaster-tolerant mechanism of cluster system guarantees 24x7 business high availability.

A cluster of one or a few servers down, there will be a backup server to take over the business, according to the level of disaster tolerance, the impact on the customer is isolated to no impact, flash recovery, interruption for a few minutes ~ ten minutes.

The cluster encapsulates the complex data redundancy mechanism and the downtime recovery mechanism, the customer believes that the entire cluster is a 24-hour fighting machine, the endurance is superb.

memcached build a structure of the cluster, with the help of Magent cache proxy Server, online borrowing diagram

Follow the cluster diagram;

The client establishes a connection with the cache proxy server, and the cache proxy server is connected with 3 hosts and 2 standby machines respectively;

The client maps key to different cache proxy server by hash and requests data to the cache proxy server, the client does not care what the memcached behind the cache proxy server, and can think that the data is available;

The cache proxy server maps the key to the memcached host and standby, determines that the host State is unavailable, or requests data to the standby when the data fails, any time the data request succeeds successfully to the client, and all requests fail to return to the client.

The state of the memcached server is taken over by the cache proxy server, requesting data from the standby when the host is down or the query data fails.

It's not like going to a chain store, not to Beijing, Shanghai, Hong Kong or Great Britain, to the store with Coke and French fries, all at once and all the same.

The figure is just convenient to explain, not necessarily this network, disaster tolerance + backup can be n+1, plus, require a certain high availability can do so; the host and the standby machine itself can also be dual-machine, and then use the N+1 disaster-tolerant network, play the role of dual backup, the telecommunications industry often use this network, the price is higher, not up.


Additional Description:

When a client connects multiple memcached or multiple cache proxies, it determines which node to access by hash mapping;

The cache proxy server accesses the memcached in the same way.

When the cache proxy server updates data to multiple memcached, some updates are processed successfully, the error log is dropped, or an alert message is generated for the operations personnel.


Memcached One of building cluster analysis

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.