Redis is a key-value storage system. Similar to memcached, it supports storing more value types, including string (string), list (linked list), set (set), Zset (sorted set-ordered collection), and hash (hash type). These data types support Push/pop, Add/remove, and intersection-set and difference sets, and richer operations, and these operations are atomic. Based on this, Redis supports sorting in a variety of different ways. As with memcached, data is cached in memory to ensure efficiency. The difference is that Redis periodically writes the updated data to disk or writes the modified operation to the appended record file, and Master-slave (Master-Slave) synchronization is implemented on this basis.
Download and install Redis on Linux CentOS6.5:
1> Switch to/home/scott (user home directory) and create a new Redis folder:
Cd/home/scott
mkdir Redis
2> download Redis under the/home/scott/redis directory using the wget command (you can download other versions from the website http://download.redis.io/releases):
CD Redis
wget http://download.redis.io/releases/redis-2.6.14.tar.gz
3> use the tar command to automatically unzip the downloaded file in the redis-2.6.14 folder and compile it using the Make command
Tar zxvf redis-2.6.14.tar.gz
Make
4> switch to the/usr/local directory and create a new Redis folder
Cd/usr/local
mkdir Redis
5> copy redis-cli and redis-server two files from/home/scott/redis/redis-2.6.14/src directory to/usr/local/redis
Cd/home/scott/redis/redis-2.6.14/src
CP Redis-cli Redis-server/usr/local/redis
6> copy redis.conf to/usr/local/redis from/home/scott/redis/redis-2.6.14 directory
CP Redis.conf/usr/local/redis
7> starting Redis
Cd/usr/local/redis
./redis-server redis.conf
8> Viewing the Redis process
ps-a | grep Redis
Redis Learning Notes (i)