如何在Windows上运行Redis ?Redis下载页面似乎提供了*nix选项。
我可以在Windows上本地运行Redis吗?
如何在Windows上运行Redis ?Redis下载页面似乎提供了*nix选项。
我可以在Windows上本地运行Redis吗?
当前回答
在windows主机上运行Redis最简单的方法之一是使用Docker Redis容器。只需启动Hyper-V,下载Docker并运行Redis
其他回答
有两种方法。您可以使用MSI安装文件或手动执行:
首先下载msi或zip文件:
You can download both files from here:https://github.com/MicrosoftArchive/redis/releases
观看视频教程(视频涵盖两种安装的示例)
查看这个安装视频教程:https://www.youtube.com/watch?v=ncFhlv-gBXQ
指导-对于不能YT工作的人:
你可以下载一个稍微过时的32位Redis预编译版本 以及64位Windows,感谢Dusan Majkic在他的GitHub页面:https://github.com/dmajkic/redis/downloads。现在就去做吧。
下载Redis之后,你需要从zip文件中提取可执行文件。 只要你使用的是比Windows XP更新的Windows版本,你就可以 应该能够提取Redis没有任何额外的软件。现在就开始吧。
当你提取了32位或64位版本的Redis到你的位置 选择(取决于您的平台和偏好;64位的Windows 可以运行32位或64位的Redis,但32位的Windows只能运行32位的Redis),你可以吗 通过双击Redis -server可执行文件启动Redis。在Redis 启动时,您应该看到一个类似于图a .1的窗口。
src: https://redis.com/ebook/appendix-a/a-3-installing-on-windows/a-3-2-installing-redis-on-window/
读到一些用户在虚拟机中运行Redis,这让我想起了Redis团队的建议:
Redis在虚拟机上运行速度较慢。虚拟化的代价是相当高的,因为许多常见的操作。(…)更喜欢在物理机上运行Redis,特别是如果你喜欢确定性延迟。在最先进的管理程序(VMWare)上,通过物理网络对虚拟机进行红色基准测试的结果几乎是物理机器的2倍,在系统和中断上花费了大量的CPU时间。
我更新了在Windows 10上使用cygwin编译和运行redis 5的方式 https://github.com/meiry/redis5_compiled_for_windows10
Redis项目并不正式支持Windows。但是,微软开放技术小组开发并维护了这个针对Win64的Windows端口。
http://redis.io/download
安装 Redis
窗户
⚫Windows 8.1及以前版本
Download Redis (msi) from the link https://github.com/MicrosoftArchive/redis/releases Run the installer Open the folder where Redis has been installed and Start redis-server to check if redis is working by clicking on redis-server Stop Redis server by typing SHUTDOWN SAVE or force quit by CTRL + C Open Start Type Environment Variables and click on edit environment variables and path Inside System variables, click on path In the next window click on new. Add a new path C:\Program Files\{Your Redis Version} Where Redis Version is the Redis version installed on your system For e.g. C:\Program Files\Redis-x64-3.2.100 Verify That Setup was Successful Check by typing redis-cli or redis-server
⚫ 视窗 10
Step Up WSL
a.以Administrator用户运行Windows Powershell
b.执行以下命令
Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux
c.修改完成后重新启动Windows
d.从windows商店https://www.microsoft.com/en-us/p/ubuntu-1804/9n9tngvndl3q?activetab=pivot%3Aoverviewtab下载Ubuntu发行版
安装和测试Redis
a.启动下载的发行版,执行如下命令
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install redis-server
redis-cli -v
注:如果安装有任何错误,请参阅本文。