1. Download Redis source package on official website
http://redis.io/can be used wget http://download.redis.io/releases/redis-3.2.3.tar.gz
2. Unzip the source package
Tar zxvf redis-3.2.3.tar.gz
Renamed MV redis-3.2.3 Redis
3. Installation
Make MALLOC=LIBC (if GCC is not installed, install GCC with yum installed gcc)
4. Make Redis a service
Copy a startup script
Cp/usr/local/redis/utils/redis_init_script/etc/rc.d/init.d/redis
Vi/etc/rc.d/init.d/redis
Save after modification
. /etc/rc.d/init.d/redis
Copy redis.config file
Mkdir/etc/redis
Cp/usr/local/redis/redis.config/etc/redis/6379.conf
To modify a bound IP address
Vi/etc/redis/6379.conf
/bind Find the binding address
Bind 192.168.1.187
Add Service
Cd/etc/rc.d/init.d
Chkconfig--add Redis
Start Redis
Service Redis Start
5. Add Environment variables
echo "Export path=" \ $PATH:/usr/local/redis/src "" >>/etc/profile
So you can use REDIS-CLI to connect to Redis.
Installing Redis under Linux