centos7 installation redis5, and remote access

Early can refer to: Redis installed .

 

Then configure Remote Access:

1. Modify the configuration file

vim redis your installation directory /redis.conf

 Modify the following:

   a will bind:. 127.0.0.1 Notes

   b.protected-mode set to no, the close protection mode

   . C You can set a password: requirepass: 123456

 

2. Shut down and restart the redis, then query redis, you can see whether you can remotely access

service redisd stop 
service redisd start 
ps -aux | grep Redis

 

If you are like me, *: 6379 is possible, if it is 127.0.0.1:6379, the only local access

 

 3. If you still can only be accessed locally, there are two reasons: 1, or port, which directly turn off the firewall 2. issue profile, where the need to re-redis configuration files to be copied to this /etc/redis/6379.conf

  Path, and cover.

These two points are done, it should be no problem!

Guess you like

Origin www.cnblogs.com/zkj1204/p/12108653.html