Redis (ix) High-Availability column "Introduction"

Source: Internet
Author: User
Tags failover redis cluster

Under the trend of Internet, the usability of user experience and service is becoming more and more important. The unavailability of any one of these services can lead to cascading functional failures.

Objective

The highly available model has gradually formed a routine:

    • Master/Slave mode
    • Cluster mode
Master/Slave mode

There are at least two service node master and Backup/slave. At the same time, only one service node serves as a standby/slave for one service--master,backup/slave. When Master goes down, it immediately switches to one of the backup/slave, and one of the backup/slave becomes master, providing services to the outside world.

It can be divided from the angle of the master/slave or no interaction:

    • Master-Slave Interaction: such as MySQL master and slave to maintain heartbeat, synchronization data
    • Master never interactive mode: Nginx Master and Standby do not interact, keepalive guarantee VIP Binding

From a failover mode perspective:

    • Automatic failover/master-slave switching with third-party components: for master-slave switching using keepalive
    • Self-failure automatic transfer of master-slave Server Software: Redis Sentinel Master-slave mode is self-implemented by Redis
    • Manual switchover, transfer failure: Operations personnel involved, through the operation to achieve the switch
Cluster mode

There are at least two service nodes that comprise the group of Service nodes, and the client often uses various routing algorithms:

    • Round robin
    • Weight
    • Random
    • Consistent Hash

So that each service node in the group provides consistent and coordinated service to the outside. That is, a cluster of one or some of the service node down, the normal node can still provide external availability services, to ensure high availability of services. Cluster mode is naturally characterized by high availability.

High Availability in Redis

The good news for Redis users is that both of these high-availability modes are implemented in Redis.

Redis provides Sentinel Sentinel mode, which is the standard implementation of master-slave mode. Sentinel Sentinel mode, divided into Sentinel and storage two types of nodes. Sentinel node is responsible for maintaining, monitoring, switching storage nodes, storage node is mainly responsible for providing data management capabilities-the single-machine Redis capability.

Redis also provides cluster mode, the Redis cluster mode is a new feature introduced by Redis 3.0. Each node in the whole cluster serves as a storage node and is externally coordinated.

Users can also simply use the shell and keepalive to achieve Redis master-slave mode, but in the Redis Perfect Sentinel mode, this way is dwarfed.

Redis (ix) High-Availability column "Introduction"

Related Article

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.