在Windows上的Redis - 配置文件
问题描述:
我刚刚在Windows上从here安装了redis服务器,并以默认模式运行服务器,未指定任何配置文件。在Windows上的Redis - 配置文件
如何将配置文件(使用Windows)链接到服务器,以及如何指定保存dtb的文件夹?
文件夹看起来是这样的:
- 文件夹:C:\ Program Files文件\ Redis的\ CONF - 有一些模板的conf文件
- 文件夹:C:\ Program Files文件\ Redis的\数据 - 空
- 文件夹:C:\ Program Files文件\ Redis的\日志 - 空
- 文件:C:\ Program Files文件\ Redis的\ Redis的-SERVER.EXE
- 文件:C:\ Program Files文件\ Redis的\ Redis的-CLI 。
答
您需要做的就是运行redis-server.exe,然后运行配置文件的文件名。
如:
D:\Coding\RedisIO>redis-server.exe redis.windows.conf
而且你需要添加/更改配置文件就行了数据库文件:
# The filename where to dump the DB
dbfilename dump.rdb
及以下的,在配置文件中的条目
# The working directory.
#
# The DB will be written inside this directory, with the filename specified
# above using the 'dbfilename' configuration directive.
#
# The Append Only File and the QFork memory mapped file will also be created
# inside this directory.
#
# Note that you must specify a directory here, not a file name.
# The working directory.
#
# The DB will be written inside this directory, with the filename specified
# above using the 'dbfilename' configuration directive.
#
# The Append Only File and the QFork memory mapped file will also be created
# inside this directory.
#
# Note that you must specify a directory here, not a file name.
dir ./