Redis is one of the most popular NoSQL systems today, and it is a key-value storage system. Similar to memcached, but largely compensates for the lack of memcached, which supports storing more value types, including string, list, set, Zset, and hash. These data types support Push/pop, Add/remove, and intersection sets and differences, and richer operations. Based on this, Redis supports sorting in a variety of different ways. Redis data is cached in the computer's memory and periodically writes the updated data to disk or writes the modification to the appended record file.
Redis website Address: http://www.redis.io/
Latest Version: 2.8.3
It is very easy to install Redis under Linux, as described in the following steps (official website):
1, download the source code, unzip and compile the source code.
$ wget http://download.redis.io/releases/redis-2.8.3.tar.gz$ tar xzf redis-2.8.3.tar.gz$ cd redis-2.8.3$ make
1.1 can also be installed with an offline package.
1, download the redis source package.
2. Upload the source package to the Linux server
3. Unzip the source package
TAR-ZXVF redis-3.0.0.tar.gz
4. Make
5. Make install
2, after the completion of the compilation, in the SRC directory, there are four executable files Redis-server, Redis-benchmark, Redis-cli and redis.conf. And then copy it to a directory.
redis3.0 New Redis-sentinel is a redis Cluster Management tool for high availability.
MKDIR/USR/REDISCP redis-server /usr/rediscp redis-benchmark/usr/rediscp redis-cli /usr/rediscp redis.conf /usr/rediscd/usr/redis
3. Start Redis service.
3.1 Front-end mode starts running directlyBin/redis-serverwill start in front-end mode, the disadvantage of front-end mode startup isSSHthe command window closesRedis-serverThis method is not recommended for the end of the program. such as:
3.2 Back-end mode start modificationredis.confconfiguration files,Daemonize YesThe backend mode starts.
1) Copy the redis.conf to the redis installation directory from the redis source directory .
2) Modify the configuration file
3) [[email protected] bin]#./redis-server redis.conf
$ redis-server redis.conf
Redis uses the 6379 port by default .
You can also change the redis.conf file to modify the port number:
4, then use the client to test whether to start successfully.
$ redis-cliredis> set foo barokredis> get foo "bar"
Introduction to Redis and installation of-centos