Redis cluster installation and configuration

Compile
make MALLOC = libc and
install to the specified directory
make install PREFIX = / opt / cluster / redis1

Redis starts
redis-server redis-conf
redis closes
redis-cli shutdown

Configure
domain name mapping
199.232.28.133 raw.githubusercontent.com to
install to the specified directory
yum -y install ruby ​​rubygems
install rvm
curl -L get.rvm.io | bash -s stable

If you encounter the following error, execute the gpg2 --recv-keys command in the error report.

Run the command curl -L get.rvm.io again | bash -s stable

The above indicates successful execution, and then execute the following command.
source / usr / local / rvm / scripts / rvm to
view the known ruby ​​version in the rvm library

rvm list known

Upgrade Ruby #Install
ruby
rvm install 2.4.0 #Use the
new version
rvm use 2.4.0 #Remove the
old version
rvm remove 2.0.0 #View the
current version
ruby --version

4. Install gem

gem install redis

5. Execute the redis-trib.rb command

The above indicates that the installation is successful, you can execute the redis-trib.rb command.

The parameter create means to create a new cluster, and --replicas 1 means to create a slave for each master.

 

The graphic can refer to the following address

https://blog.csdn.net/huwh_/article/details/79242625?depth_1-utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-7&utm_source=distribute.pc_relevant.none-task-blog-BlogCommendFromBaidu-7

Guess you like

Origin www.cnblogs.com/mostearth/p/12735075.html