1: First command line to download the installation package
wget http://download.redis.io/releases/redis-2.8.13.tar.gz
2: Unzip
Tar xzf redis-2.8.13.tar.gz
3: Enter directory redis-2.8.13
CD redis-2.8.13
4: Compiling the installation
Make & make Install
5: No error, the installation is complete!
6: Find the Redis configuration file redis.conf
Common configuration properties are as follows:
1:daemonize: Whether the next process runs, default is no, modify to Yes
2:timeout 300: Timeout time, default is 300s, write 300
3:redis Log Storage Path
LogFile/path Address
(my: LogFile '/usr/local/redis/redis.log ')
7.redis Boot
First find three files, put in the same directory, (can be copied back and forth)
File 1/usr/local/bin/redis-cli (this file is generated in this directory after you compile and install Redis)
File 2/usr/local/bin/redis-server (this file is generated in this directory after you compile and install Redis)
File 3 The Redis directory you installed under the redis.conf
(I think ha, should be any of them three anywhere in the line, because the files 1 and 2 together, so I copied the redis.conf to the bin below) CP redis.conf/usr/local/bin/
Last boot::./redis-server redis.conf
8: How to use
Enter/usr/local/bin/execution REDIS-CLI
Direct input REDIS-CLI can be
And then you can try it.
Store:
Set Key Name "Value value"
Remove
Get "Key Name"
Example: Set name 123
Ok
Remove Get Name
Output 123
Linux installation Redis