To view the installation environment:
[Email protected] ~]# cat/proc/version
Linux version 2.6.32-573.22.1.el6.x86_64 ([email protected]) (GCC version 4.4.7 20120313 (Red Hat 4.4.7-16) (gcc)) #1 SMP Wed Mar 03:35:39 UTC 2016
[Email protected] ~]# cat/etc/issue
CentOS Release 6.7 (Final)
Kernel \ r on an \m
1, download, unzip, compile
Download:
[Email protected] ~]# cd/usr/local/
[Email protected] local]# wget http://download.redis.io/releases/redis-3.0.7.tar.gz
--2016-03-29 18:58:36--http://download.redis.io/releases/redis-3.0.7.tar.gz
Parsing host Download.redis.io ... 109.74.203.151
Connecting download.redis.io|109.74.203.151|:80 ...
Extract:
[Email protected] ~]# tar xzf redis-3.0.7.tar.gz
Compile:
[Email protected] redis-3.0.7]# CD redis-3.0.7
[[email protected] redis-3.0.7]# make
2. Compiled binaries (i.e. our Redis program) under the src directory under the redis-3.0.7 folder
Start the service:
[[Email protected] ~]# CD src
[Email protected] src]#./redis-server
The above interface appears, stating that the service started successfully.
3. Testing
To start with a client connection:
[Email protected] src]#./redis-cli
127.0.0.1:6379> keys *
(empty list or set)
Add, Get Data:
127.0.0.1:6379> Set username slov7ch
Ok
127.0.0.1:6379> Get username
"Slov7ch"
127.0.0.1:6379>
CentOS Installation Redis3.0.7