Apsaradb for redis is a powerful nosql database. Compared with memcached, apsaradb for redis provides richer data types, including string, hash, list, set, and sorted set. It also supports data persistence. The optical string type is more powerful than memcached. It provides more flexible operations such as obtaining/setting substrings and bit. Other types are not supported by memcached. Redis developers are very powerful and frequently updated.
The compilation and installation of redis is very simple. The steps are as follows:
# Wget http://redis.googlecode.com/files/redis-2.4.4.tar.gz
# Tar-xzf redis-2.4.4.tar.gz
# Cd redis-2.4.4
# Make
# Make prefix =/usr/local/redis-2.4.4 install
# Cp redis. CONF/usr/local/redis-2.4.4
So far, compilation and installation are complete.
Start the service:
# Cd/usr/local/redis-2.4.4
Modify the configuration file and change the "daemonize no" line to "daemonize yes" to run it in the background.
# Vim redis. conf
Start redis Service
#./Bin/redis-server redis. conf
Close the service:
#./Bin/redis-cli-P 6379 Shutdown
Simple operation:
#./Bin/redis-cli
Redis 127.0.0.1: 6379> set key hi
OK
Redis 127.0.0.1: 6379> get key
"Hi"
Appendix:
Redis Official Website: http://redis.io/