windows下的环境搭建配置redis

windows下的环境搭建配置redis

ID:34727097

大小:128.25 KB

页数:17页

时间:2019-03-10

windows下的环境搭建配置redis_第1页
windows下的环境搭建配置redis_第2页
windows下的环境搭建配置redis_第3页
windows下的环境搭建配置redis_第4页
windows下的环境搭建配置redis_第5页
资源描述:

《windows下的环境搭建配置redis》由会员上传分享,免费在线阅读,更多相关内容在工程资料-天天文库

1、下载地址:https://github.com/dmajkic/redis/downloads下载下来的包里有两个,一个是32位的,一个是64位的。根据自己的实情情况选择,我的是32bit,把这个文件夹复制到其它地方,比如D:redis目录下。打开一个cmd窗口 使用cd命令切换目录到d:redis 运行redis-server.exeredis.conf 如果想方便的话,可以把redis的路径加到系统的环境变量里,这样就省得再输路径了,后面的那个redis.conf可以省略,如果省略,会启用默认的。输入之后,会显示如下界面: 这时候别启一个cmd窗口,原来的不要关闭,不然就无法访问服

2、务端了切换到redis目录下运行redis-cli.exe-h127.0.0.1-p6379出现下图: 这时候,就已经完成配置了,现在说下它的的redis.conf配置文件。[plain] viewplaincopy1.001  2.# Redis configuration file example  3.002  4.   5.003  6.# Note on units: when memory size is needed, it is possible to specifiy  7.004  8.# it in the usual form of 1k 5GB 4M and so

3、 forth:  9.005  10.#  11.006  12.# 1k => 1000 bytes  13.007  14.# 1kb => 1024 bytes  15.008  16.# 1m => 1000000 bytes  17.009  18.# 1mb => 1024*1024 bytes  19.010  20.# 1g => 1000000000 bytes  21.011  22.# 1gb => 1024*1024*1024 bytes  23.012  24.#  25.013  26.# units are case insensitive so 1GB 1G

4、b 1gB are all the same.  27.014  28.   29.015  30.# By default Redis does not run as a daemon. Use 'yes' if you need it.  31.016  32.# Note that Redis will write a pid file in /var/run/redis.pid when daemonized.  33.017  34.daemonize no   35.018  36.Redis默认不是以守护进程的方式运行,可以通过该配置项修改,使用yes启用守护进程  37.0

5、19  38.   39.020  40.# When running daemonized, Redis writes a pid file in /var/run/redis.pid by  41.021  42.# default. You can specify a custom pid file location here.  43.022  44.pidfile /var/run/redis.pid  45.023  46.当Redis以守护进程方式运行时,Redis默认会把pid写入/var/run/redis.pid文件,可以通过pidfile指定  47.024  48.

6、# Accept connections on the specified port, default is 6379.  49.025  50.# If port 0 is specified Redis will not listen on a TCP socket.  51.026  52.port 6379  53.027  54.指定Redis监听端口,默认端口为6379  55.028  56.# If you want you can bind a single interface, if the bind option is not  57.029  58.# specif

7、ied all the interfaces will listen for incoming connections.  59.030  60.#  61.031  1.# bind 127.0.0.1  2.032  3.绑定的主机地址  4.033  5.# Specify the path for the unix socket that will be used to listen for  6.034  7.

当前文档最多预览五页,下载文档查看全文

此文档下载收益归作者所有

当前文档最多预览五页,下载文档查看全文
温馨提示:
1. 部分包含数学公式或PPT动画的文件,查看预览时可能会显示错乱或异常,文件下载后无此问题,请放心下载。
2. 本文档由用户上传,版权归属用户,天天文库负责整理代发布。如果您对本文档版权有争议请及时联系客服。
3. 下载前请仔细阅读文档内容,确认文档内容符合您的需求后进行下载,若出现内容与标题不符可向本站投诉处理。
4. 下载文档时可能由于网络波动等原因无法下载或下载错误,付费完成后未能成功下载的用户请联系客服处理。