OS:Centos 6.9
Redis Version:“V4.0.2
1.上传包至服务器
2. tar -zxvf packageName
3. ../../src 下执行 resdis-server redis.conf ,启动服务
4.redis-cli,开始show
参考步骤:
步骤一:
下载安装包:http://redis.io,选择stable版本
步骤二:
编译源程序:
tar zxvf redis-3.0.4.tar.gz
cd redis-3.0.4
make
cd src && make install
步骤三:
移动文件
mkdir -p /usr/local/redis/bin
mkdir -p /usr/local/redis/etc
mv /lamp/redis-3.0.4/redis.conf /usr/local/redis/etc
cd /lamp/redis-3.0.4/src
mv mkreleasehdr.sh redis-benchmark redis-check-aof redis-check-dump \
redis-cli redis-server /usr/local/redis/bin
步骤四:
启动redis服务:
/usr/local/redis/bin/redis-server /usr/local/redis/etc/redis.conf
步骤五:
客户端连接
/usr/local/redis/bin/redis-cli
步骤六:
停止redis实例
方法1)/usr/local/redis/bin/redis-cli shutdown
方法2)pkill redis-server