Redis compilation and Installation

Source: Internet
Author: User

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/

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.