Home > Database > Redis > body text

redis user authentication setting method

Release: 2020-04-25 09:32:54
forward
3342 people have browsed it

redis user authentication setting method

After installing Redis, there has been no security or user control over it. Later, in response to business requirements, user verification was added to Redis. The following is the specific configuration:

Set verification password

There are several ways to set verification password:

1) Modify the configuration file redis.conf settings:

redis user authentication setting method

2) You can set the password and get the current user password through the config command, as follows:

redis 127.0.0.1:6379[1]> config set requirepass 123456  
OK  
redis 127.0.0.1:6379[1]> config get requirepass  
1) "requirepass"  
2) "123456"
Copy after login

3) After setting the verification password, the redis service needs to pass the password verification before it can be shut down, so the command is modified For:

$ redis-cli –a 123456 shutdown
Copy after login

For more redis knowledge, please pay attention to the redis introductory tutorial column.

The above is the detailed content of redis user authentication setting method. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!