当前位置: 移动技术网 > 科技>操作系统>windows > 在Windows上安装Redis

在Windows上安装Redis

2019年05月11日  | 移动技术网科技  | 我要评论
使用Chocolatey(Windows包管理工具)安装 官方安装说明 https://chocolatey.org/install 两种方法 在Cmd命令中键入 在PowerShell命令中输入 安装Redis 官方安装说明 https://chocolatey.org/packages/redi ...

使用chocolatey(windows包管理工具)安装

官方安装说明 

两种方法

  • 在cmd命令中键入
@"%systemroot%\system32\windowspowershell\v1.0\powershell.exe" -noprofile -inputformat none -executionpolicy bypass -command "iex ((new-object system.net.webclient).downloadstring('https://chocolatey.org/install.ps1'))" && set "path=%path%;%allusersprofile%\chocolatey\bin"
  • 在powershell命令中输入
set-executionpolicy bypass -scope process -force; iex ((new-object system.net.webclient).downloadstring('https://chocolatey.org/install.ps1'))

安装redis

官方安装说明 

在命令中键入

choco install redis-64

默认安装目录 c:\programdata\chocolatey\lib\redis-64。安装目录中有相关介绍文档《redis on windows.docx》、《redis on windows release notes》、《windows service documentation.docx》

在windows服务中运行redis

参考安装目录中的文档《windows service documentation.docx》

安装到windows服务

在当前目录命令中键入

redis-server --service-install redis.windows.conf

以读取配置文件 redis.windows.conf ,中包括端口号(port 端口号)、授权秘钥(requirepass 秘钥)等

启动服务

在当前目录命令中键入

redis-server --service-start

 本文地址:

如您对本文有疑问或者有任何想说的,请点击进行留言回复,万千网友为您解惑!

相关文章:

验证码:
移动技术网