1、下載
Window 下載地址:https://github.com/MSOpenTech/redis/releases
查找版本對應的一個MSI或者zip文件下載
2、安裝
MSI文件需要安裝
zip文件解壓后可直接運行
3、啟動:
打開 cmd 窗口 ,使用cd命令,進入redis目錄到(例如:C:\redis)運行 redis-server.exe,啟動服務。不能關閉cmd窗口,關閉后,redis服務就退出了
4、使用:
這時候另啟一個cmd窗口,進入redis目錄下運行 redis-cli.exe -h 127.0.0.1 -p 6379 。
設置鍵值對 沒有空格的單詞可以不加引號
set theFirstredis "the first redis test"
取出鍵值對
get theFirstredis