首页 > 代码库 > Redis On Windows
Redis On Windows
Microsoft Open Tech group 在 GitHub上开发了一个REDIS Win64的版本,项目地址是:https://github.com/MSOpenTech/redis
可以在项目主页右边找到 zip包下载地址: https://github.com/MSOpenTech/redis/archive/2.8.zip
下载解压,没什么好说的,在解压后的bin目录下有以下这些文件:
redis-benchmark.exe #基准测试redis-check-aof.exe # aofredis-check-dump.exe # dumpredis-cli.exe # 客户端redis-server.exe # 服务器redis.windows.conf # 配置文件
参考RedisService.docx 文件,启动脚本如下:
redis-server redis.windows.conf
D:\redis-2.8.17>redis-server.exe redis.windows.conf[4692] 27 Nov 12:14:05.995 #The Windows version of Redis allocates a memory mapped heap for sharing withthe forked process used for persistence operations. In order to share thismemory, Windows allocates from the system paging file a portion equal to thesize of the Redis heap. At this time there is insufficient contiguous freespace available in the system paging file for this operation (Windows error0x5AF). To work around this you may either increase the size of the systempaging file, or decrease the size of the Redis heap with the --maxheap flag.Sometimes a reboot will defragment the system paging file sufficiently forthis operation to complete successfully.Please see the documentation included with the binary distributions for moredetails on the --maxheap flag.Redis can not continue. Exiting.
根据提示,是 maxheap 标识有问题,打开配置文件 redis.windows.conf ,搜索 maxheap , 然后直接指定好内容即可.
# maxheap <bytes>maxheap 1024000000
然后再次启动,OK,成功.
D:\redis-2.8.17>redis-server.exe redis.windows.conf _._ _.-``__ ‘‘-._ _.-`` `. `_. ‘‘-._ Redis 2.8.17 (00000000/0) 64 bit .-`` .-```. ```\/ _.,_ ‘‘-._ ( ‘ , .-` | `, ) Running in stand alone mode |`-._`-...-` __...-.``-._|‘` _.-‘| Port: 6379 | `-._ `._ / _.-‘ | PID: 2700 `-._ `-._ `-./ _.-‘ _.-‘ |`-._`-._ `-.__.-‘ _.-‘_.-‘| | `-._`-._ _.-‘_.-‘ | http://redis.io `-._ `-._`-.__.-‘_.-‘ _.-‘ |`-._`-._ `-.__.-‘ _.-‘_.-‘| | `-._`-._ _.-‘_.-‘ | `-._ `-._`-.__.-‘_.-‘ _.-‘ `-._ `-.__.-‘ _.-‘ `-._ _.-‘ `-.__.-‘[2700] 27 Nov 12:15:44.958 # Server started, Redis version 2.8.17[2700] 27 Nov 12:15:44.958 * DB loaded from disk: 0.000 seconds[2700] 27 Nov 12:15:44.958 * The server is now ready to accept connections on port 6379
Redis On Windows
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。