1. Redis download, some functions are not supported in versions before 2.6, choose to download a newer version after 3.0
Download address: https://github.com/MSOpenTech/redis/releases
2. Run redis
Run cmd as administrator, cd into the redis file cd /d E:\Redis-x64-3.2.100
After the command line redis-server.exe redis.windows.conf prompts to run successfully
Start another cmd and switch to the folder
Run redis-cli.exe -h 127.0.0.1 -p 6379 -a 123456 -p set port -a set password
3. Set the redis service, the default port 6379
Start another cmd and switch to the folder
run redis-server --service-install redis.windows.conf
Open cmd and enter services.msc, Redis appears in the service, start the service by itself
4. Set up redis multi-instance
Copy a copy of [redis.windows-service.conf] and rename it to [redis.windows-service6380.conf]
Modify [port 6379] in [redis.windows-service6380.conf] to [port 6380], and modify [logfile "Logs/redis_log_6380.txt"] to [logfile "Logs/redis_log_6381.txt"],
If [syslog-enabled] is set to [no], this item does not need to be modified
run cmd as administrator
Run edis-server redis.windows-service6380.conf, after that the cursor will keep blinking
run redis-cli.exe -h 127.0.0.1 -p 6380 -a 123456
Open cmd to set the redis service, run redis-server --service-install redis.windows-service6380.conf --service-name redis6380 --port 6380
Open cmd and enter services.msc, Redis6380 will appear in the service, start the service by itself
Reference documentation:
https://blog.csdn.net/baidu_33465676/article/details/75530477
https://blog.csdn.net/wangzl1163/article/details/64128123