Getting started with installing redis and getting started with redis

Source: Internet
Author: User
Tags redis version

Getting started with installing redis and getting started with redis

Official redis Website: redis. io

Redis version is using redis-3.2.2

$ Wget http://download.redis.io/releases/redis-3.2.2.tar.gz

$ Tar xzf redis-3.2.2.tar.gz

$ Redis-3.2.2 cd

$ Make

$ Src/redis-server

$ Src/redis-cli
Redis> set foo bar
OK
Redis> get foo
"Bar"

 

Easy, redis getting started

Modify the redis. conf file:

1. Add the password. It is recommended to keep it long and add youpassword after requirepass.

2. Modify the bind, that is, the ip address you bind.

There are several problems: at startup,/path/to/redis will be searched by default. if the conf file cannot be found, an error will be reported. Solution: redis-server .. /redis. conf, manually specify the location where redis loads the conf at startup

When someone else's ip address needs to be able to access redis, it says on the Internet that the bind is replaced, but it is still divided into redis versions,Redis version problems, that is, when less than 3.0.1 does not produce this error, higher than production

This problem occurs.

Error: Creating Server TCP listening socket *: 6379: unable to bind socket

Specific solution:

A. Disable the IPv6 NIC (the specific method is Baidu, which is not described here)

B. Add bind 0.0.0.0 to redis. conf.

     

Specific reasons:

A. redis accepts IPv4 access mode. IPv6 does not accept

B. Add bind 0.0.0.0 (this is the end of the article)

 

Not complete...

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.