数据库
首页 > 数据库> > window 安装redis

window 安装redis

作者:互联网

下载地址:https://github.com/tporadowski/redis/releases

修改配置文件:requirepass  passwd

因redis-server 启动命令只是临时启动,关闭窗口服务会关闭,所以需要后台运行。

安装

安装命令:redis-server.exe --service-install redis.windows.conf --loglevel verbose

启动服务命令:redis-server.exe  --service-start

关闭服务命令:redis-server.exe  --service-stop

报错

D:\redis5>redis-server.exe --service-install redis.windows.conf --loglevel verbo
se
[2084] 30 Jul 09:39:52.913 # HandleServiceCommands: system error caught. error c
ode=1073, message = CreateService failed: 指定的服务已存在。

解决

1)先卸载服务:
redis-server --service-uninstall
2)然后再安装:
redis-server.exe --service-install redis.windows.conf --loglevel verbo
启停: 
启动服务:redis-server --service-start
停止服务:redis-server --service-stop
D:\redis5>redis-server --service-uninstall
[4924] 30 Jul 09:43:15.077 # Redis service successfully uninstalled.

D:\redis5>redis-server --service-install redis.windows.conf --loglevel verbose
[2480] 30 Jul 09:43:18.065 # Granting read/write access to 'NT AUTHORITY\Network
Service' on: "D:\redis5" "d:\redis5"
[2480] 30 Jul 09:43:18.077 # Redis successfully installed as a service.

 

标签:exe,service,--,redis,server,redis5,window,安装
来源: https://www.cnblogs.com/rtnb/p/16534402.html