Home > Database > Redis > How to set redis password in Linux system

How to set redis password in Linux system

王林
Release: 2023-05-26 21:00:46
forward
3271 people have browsed it

After installing redis under the Linux system, the default is no password, you need to set the password yourself.

How to set redis password in Linux system

  1. First open the configuration file vim redis.conf

  2. Search for /requirepass# in the command line state

  3. ##Then add requirepass 123 in insert mode

  4. Close redis /usr/local/redis/bin/redis-cli shutdown

  5. Start redis/usr/local/redis/bin/redis-server /usr/local/redis/etc/redis.conf

  6. Enter the client to view/ usr/local/redis/bin/redis-cli

  7. auth password can be used to enter

  8. Check the password under the client config get requirepass

If you have a password, you can log in first and then verify

How to set redis password in Linux system

You can also log in and verify directly

How to set redis password in Linux system

What is a Linux system

Linux is a UNIX-like operating system that is free to use and spread freely. It is a POSIX-based multi-user, multi-task, multi-thread and multi-CPU system. Operating system, Linux can run major Unix tool software, applications and network protocols.

The above is the detailed content of How to set redis password in Linux system. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:yisu.com
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