Windows环境搭建最新版NoSQL数据库Redis数据存储服务

x33g5p2x  于2022-02-07 转载在 Redis  
字(1.5k)|赞(0)|评价(0)|浏览(399)

(1)下载安装最新Windows版的Redis。

Redis官方目前没有直接给出Windows版本的发行版本,网上一搜,给出的多数是老旧的微软在2016年制作的Windows版本Redis发行版本。现在github上有一个,专注于Windows版本的Redis发行,跟进比较及时,最新版的Redis之Windows版本,链接地址:

Releases · tporadowski/redis · GitHub

https://github.com/tporadowski/redis/releases

下载解压后,在Windows控制台进入Redis程序文件目录里面,启动命令:

redis-server

就启动Redis数据库了。此时控制台输出日志:

Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf

                .
           .-__ ''-._       _.-    .  .  ''-._           Redis 5.0.14 (a7c01ef4/0) 64 bit
  .-.-```.  ```\/    _.,_ ''-._  (    '      ,       .-`  | `,    )     Running in standalone mode  |`-._`-...-` __...-.-.|'_.-'|     Port: 6379  |    -.   ._    /     _.-'    |     PID: 55604  -._    -._  -./  .-'    .-'
 |-._-.
   -.__.-'    _.-'_.-'|  |    -.
-._        _.-'_.-'    |           http://redis.io  -._    -._-..-'.-'    .-'
 |-._-.
   -.__.-'    _.-'_.-'|  |    -.
-._        _.-'_.-'    |  -._    -._-.
.-'_.-'    _.-'
      -._    -..-'    _.-'
          -._        _.-'              -.
.-'

(2)修改Redis数据存储目录和dump日志目录。

可以看到,日志中输出了一个警告,说没有提供配置文件:

# Warning: no config file specified, using the default config. In order to specify a config file use redis-server /path/to/redis.conf

Windows下载后的包,已经包含两个关于Redis的配置文件:

redis.windows.conf
redis.windows-service.conf

打开redis.windows.conf文件,这里有关Redis的配置,简单配置数据库存储路径,存储路径默认是在:

dir ./

修改为自定义的一个目录,比如D:\redis\data:

dir D:/redis/data

修改完毕后,这次启动Redis指明具体的配置文件路径:

redis-server  D:\redis\bin\redis.windows.conf

就完全正常启动了。

提供两个免费、开源的Redis GUI可视化管理工具:

Releases · ekvedaras/redis-gui · GitHub🔬 Modern graphical user interface to peek into redis database - Releases · ekvedaras/redis-gui

https://github.com/ekvedaras/redis-gui/releases

https://github.com/qishibo/AnotherRedisDesktopManager/releases

https://github.com/qishibo/AnotherRedisDesktopManager/releases

相关文章

微信公众号

最新文章

更多