1、装置wget
yum -y install wget
2、/opt门路下下载redis
wget http://download.redis.io/releases/redis-6.2.1.tar.gz
3、装置gcc
yum install gcc
gcc --version
4、解压redis包
tar -zxvf redis-6.2.1.tar.gz
5、cd redis-6.2.1/下,执行make编译成C
6、执行make install,装置实现
7、默认装置地位
/usr/local/bin
8、根本应用(配置后盾启动)
/opt/redis-6.2.1/redis.conf
复制配置文件
cp redis.conf /etc/redis.conf
编辑/etc/redis.conf
daemonize no批改为yes
启动
cd /usr/local/bin
./redis-server /etc/redis.conf
查看redis状态
ps -ef|grep redis
通过客户端连贯redis
./redis-cli
127.0.0.1:6379> ping 打印pong示意联通状态失常
敞开
127.0.0.1:6379> shutdown
或
kill -9 <过程号>
发表回复