Java development environment of Redis

View more Java development environment configuration, click the "Java development environment configuration Filmography"

Lu Zhang: Redis installation tutorial

1) to download the installation package on Github

https://github.com/MSOpenTech/redis/tags

Recommended to download compressed (zip) format, namely the installation is complete decompression

 

2) Set the password service

2.1 Starting redis: dos into the installation directory, execute redis-server redis.windows.conf, redis successful start, the default port 6379;

Set redis service: dos into the installation directory, execute redis-server --service-install redis.windows-service.conf --loglevel verbose;

Uninstall service: dos into the installation directory, execute redis-server --service-uninstall;

Open service: dos into the installation directory, execute redis-server --service-start;

Stop Service: dos into the installation directory, execute redis-server --service-stop;

Entering redis: dos into the installation directory, perform redis-cli.exe -h localhost -p 6379;

 

2.2 Setting password redis

Method 1: Locate the installation directory redis.conf or redis.windows.conf configuration file, there is no need to Baidu to find and create, find requirepass foobared in the configuration file, the foobared by changing his password, pay attention to the front of the pound sign removed, although the command without a password can enter redis, but has been unable to operate, and encryption start-up mode redis-cli.exe -h localhost -p 6379 -a 123456 (behind a password), found normal operation, encryption effect.

 

Second way: After entering redis, execute config set requirepass 123 (the latter is the password), and found that the operation can not be performed, 6379 -a 123 log in with the new password redis-cli.exe -h localhost -p, execute config get requirepass find password modified, restart redis password will expire.

 

Three ways: do not set up the service, create a script file in startup.bat redis directory, saving startup command inside: redis-server.exe redis.windows.conf, every time you start to click on this (recommended)

 

3) install a graphical interface

Baidu Download redis-desktop-manager can be installed

 

Guess you like

Origin www.cnblogs.com/xdzy/p/10992690.html