redis_cluster集群搭建
redis_cluster部署
yum install gcc gcc-c++ gcc-g77
tar -zxvf tcl8.6.1-src.tar.gz
rm -rf tcl8.6.1-src.tar.gz
mv tcl8.6.1 /usr/local/tcl8
cd /usr/local/tcl8.6.1/unix/
./configure
make && make install
tar -zxvf redis-3.2.8.tar.gz
rm -f redis-3.2.8.tar.gz
mv redis-3.2.8 /usr/local/redis3
cd /usr/local/redis3
make
make test
make install
cp /usr/local/redis3/utils/redis_init_script /etc/init.d/redis_6379
vi /etc/init.d/redis_6379
修改第6行 REDISPORT=6379
$CLIEXEC -a “redis-pass” -h 本地ip -p $REDISPORT shutdown
$CLIEXEC -a “redis-pass” -h 192.168.199.128 -p $REDISPORT shutdown
mkdir -p /etc/redis-cluster (存放redis的配置文件)
mkdir -p /var/log/redis