2 ways to share _redis under Ubuntu installation Redis

Source: Internet
Author: User
Tags redis install redis redis server

Objective

Redis is currently recognized as the fastest memory based on the key value of the database, but Redis's shortcomings are also very obvious, only provide the most basic hash set, list, sorted set, etc. based on data types, no table, no schema, no index, no foreign keys, lack of int/ Date and other basic data types, multi-condition query needs to be implemented indirectly through set inline (sinter,zinterstore) and connection, inconvenient operation, low development efficiency and poor maintainability; therefore, it is generally not used as a complete database alone, Many web sites use Redis as a cache and session state storage layer, which is then used in combination with other databases.

Note: This article is installed in version 3.0.6, you can download the latest stable version to Https://redis.io/download

Method One

$ wget http://download.redis.io/releases/redis-3.0.6.tar.gz
$ tar xzf redis-3.0.6.tar.gz
$ cd redis-3.0.6
$ make
$ cd src

After make, the redis-3.0.6/src redis-server service program and the client program appear in the directory redis-cli . will be redis-3.0.6/redis.conf copied to the SRC directory

Start the Redis service side

./redis-server redis.conf

Open another terminal at this time, start the client

 
 

Test run

127.0.0.1:6379> set name Tom
OK
127.0.0.1:6379> get name
"Tom"

The installation was successful.

Method Two

Install online using the following command

$sudo apt-get Update
$sudo apt-get install Redis-server

Start Redis server and client separately

$ redis-server
$ redis-cli

Summarize

The above is the entire content of this article, I hope the content of this article for everyone's study or work can bring certain help, if you have questions you can message exchange.

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.