Redis cluster and master-slave replication

Source: Internet
Author: User
Tags redis cluster

First, Introduction

Redis supports synchronizing data to multiple slave, a feature that is useful for improving read performance

1) Master can have more than one slave

2) In addition to multiple slave connected to the same master, slave can also be connected to other slave to form a graphic structure

3) Master-slave replication does not block the primary, meaning that when one or more slave and master connections are replicated, master can continue to process requests from clients, whereas slave will block when the data is first synchronized and cannot handle client requests

4) Master-slave replication can be used to improve the scalability of the system, we can use multiple slave specifically responsible for client read requests, can do data redundancy

5) You can disable data persistence in master, just comment out the save configuration for Master Profile redis.conf, and then only configure persistence in slave

Second, Demo

Bo Master here is not installed more than one machine, could have built a local area network with three virtual machines, to realize the master-slave copy of Redis, here steal lazy, use to start a number of configuration files to replace, here a total of three redis.conf files, as follows:

[[Email protected] ~]$ su Password: [[email protected] jacky]# CD/etc/redis[[email protected] redis]# ls-L Total Dosage176-rw-r--r--.1Root root41576November3  A:Genevaredis6379.conf-rw-r--r--.1Root root41560November3  -: ,redis6380.conf-rw-r--r--.1Root root41560November3  -: ,Redis6381.conf

2.1, mainly modify the following information of the configuration file

Redis cluster and master-slave replication

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.