Take you quickly install and deploy Redis (b)

I believe we read an article on the rapid understanding Redis (a) of Redis have to understand it now, the following niche lead the rapid installation and deployment environment about it! ! ! ! ! !

Redis installation and deployment

redis package link extraction code: g60y

Step One: Download the installation package redis
node01服务器执行以下命令下载redis安装包
cd /export/softwares   进入安装包所在目录将安装包上传到此目录
Step two: redis unzip the archive to the specified directory
node01执行以下命令进行解压redis
cd /export/softwares
tar -zxvf redis-3.2.8.tar.gz -C ../servers/   解压到上级目录下
The third step: install the C runtime environment
node01执行以下命令安装C程序运行环境
yum -y install gcc-c++
Step four: Install a newer version of tcl
The first way: using compressed installation (not recommended)
node01执行以下命令下载tcl安装包
cd /export/softwares
wget http://downloads.sourceforge.net/tcl/tcl8.6.1-src.tar.gz
解压tcl
tar -zxvf tcl8.6.1-src.tar.gz -C ../servers/
进入指定目录
cd ../servers/tcl8.6.1/unix/
./configure
make  && make  install
The second way, the online installation tcl (highly recommended)
node01执行以下命令在线安装tcl
yum  -y  install  tcl
Step five: compiling redis (written in C language software need to be recompiled)
node01执行以下命令进行编译:
cd /export/servers/redis-3.2.8/
make  && make   install
看到如下表示编译成功

Here Insert Picture Description

Step Six: redis modify configuration files
node01执行以下命令修改redis配置文件

cd /export/servers/redis-3.2.8/
mkdir -p /export/servers/redis-3.2.8/logs
mkdir -p /export/servers/redis-3.2.8/redisdata
vim redis.conf
找到这几个 改一下  (切记一定要先进入编辑模式在进行修改)

bind node01
daemonize yes
pidfile /var/run/redis_6379.pid
logfile "/export/servers/redis-3.2.8/logs/redis.log"
dir /export/servers/redis-3.2.8/redisdata

Here Insert Picture Description
Here Insert Picture Description
Here Insert Picture Description
Here Insert Picture Description
Here Insert Picture Description

Step Seven: Start redis
node01执行以下命令启动redis
cd  /export/servers/redis-3.2.8/src
redis-server  ../redis.conf
Step eight: Connect the redis client
node01执行以下命令连接redis客户端
cd /export/servers/redis-3.2.8/src
redis-cli -h node01
Renderings:
看到下图这样  证明连接redis客户端连接成功啦!!!!!!

Here Insert Picture Description

Installation and deployment environment on which to end it! !
Next we will update some redis data types and some simple operations!
To help you point to a niche like it! ! ! ! ! ! (# . #)
Published 37 original articles · won praise 19 · views 10000 +

Guess you like

Origin blog.csdn.net/weixin_44466534/article/details/104885283