env
yum install -y wget make gcc tcl
编译安装
make distclean && make && make install
配置文件
sh utils/install_server.sh
主从配置
# slaveof <masterip> <masterport>
# masterauth <master-password>
slaveof redis.erver.com 6379
masterauth redisPass
系统服务
cat > /usr/lib/systemd/system/redis.service <<END
[Unit]
Description=redis
After=network.target
[Service]
Type=forking
ExecStart=/usr/local/bin/redis-server /etc/redis/6379.conf
ExecStop=/usr/local/bin/redis-cli shutdown
PrivateTmp=true
[Install]
WantedBy=multi-user.target
#systemctl enable redis
#systemctl daemon-reload
END
评论区