Comprehensive Evaluation of mainstream NoSQL databases-Redis

Source: Internet
Author: User
The NoSQL product to be evaluated in this article is Redis. It can be understood as a Key-Value data structure operation. The data is stored in the memory and regularly refreshed to the disk.

The NoSQL product to be evaluated in this article is Redis. It can be understood as a Key-Value data structure operation. The data is stored in the memory and regularly refreshed to the disk.

The NoSQL product to be evaluated in this article is Redis. It can be understood as a Key-Value data structure operation. The data is stored in the memory and regularly refreshed to the disk, high read/write efficiency has attracted much attention. Sina Weibo in China uses Redis to store user relationships and count on a large scale.

Jieshao

According to the official statement, Redis is developed using ansi c and runs on Most POSIX (Linux, * BSD, OS X, and Solaris) systems. It does not officially support Windows versions. The latest version is 2.2.11, which fixes a bug caused by traversal optimization in version 2.2.7.

Unlike the common Key-Value structure, Redis's Key supports flexible data structures, including strings, hashes, lists, sets, and sorted sets. These flexible data structures enrich the application scenarios of Redis and meet the flexible storage needs of more businesses.

Redis data is stored in the memory, and the underlying implementation of the epoll event loop is self-written, rather than the use of open-source libevent and other general frameworks, so the Read and Write efficiency is very high. To achieve data persistence, Redis supports regular refresh (which can be implemented through configuration) or log writing to save data to the disk.

Installation and Use

Because there is no third-party package dependency, Redis installation is very simple:

$ Wget

$ Tar xzf redis-2.2.11.tar.gz

$ Redis-2.2.11 cd

$ Make

After the installation is complete, execute the redis-server under the src directory to start the Redis process. However, you 'd better configure the redis. conf file first. The following are common parameters to note:

Daemonize yes

Specify that Redis runs as a daemon.

Pidfile/home/banping/redis. pid

When Redis runs as a daemon, it writes the pid to the specified file.

Port 6379

Specifies the listening port. The default port is 6379.

Bind 192.168.0.35

The IP address of the bound host.

Logfile stdout

Specifies the log record method. The default value is standard output.

Databases 16

Set the number of databases.

Save

The default configuration file of Redis provides three conditions:

Save 900 1

Save 300 10

Save 60 10000

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.