Configuration Redis正在受保护模式下运行

Configuration Redis正在受保护模式下运行,configuration,redis,streaming,benchmarking,Configuration,Redis,Streaming,Benchmarking,我正在尝试在4个虚拟机上运行扩展的Yahoo基准测试。每次我尝试运行“STORM_TEST”时,都会出现以下错误。我尝试配置'redis.conf',但仍然得到相同的错误。我已经在下面显示了错误和我的'redis.conf'文件 错误: Caused by: java.lang.Exception: DENIED Redis is running in protected mode because protected mode is enabled, no bind address was sp

我正在尝试在4个虚拟机上运行扩展的Yahoo基准测试。每次我尝试运行“STORM_TEST”时,都会出现以下错误。我尝试配置'redis.conf',但仍然得到相同的错误。我已经在下面显示了错误和我的'redis.conf'文件

错误:

Caused by: java.lang.Exception: DENIED Redis is running in protected mode because protected mode is enabled, no bind address was specified, no authentication password is requested to clients. In this mode connections are only accepted from the loopback interface. If you want to connect from external computers to Redis you may adopt one of the following solutions: 1) Just disable protected mode sending the command 'CONFIG SET protected-mode no' from the loopback interface by connecting to Redis from the same host the server is running, however MAKE SURE Redis is not publicly accessible from internet if you do so. Use CONFIG REWRITE to make this change permanent. 2) Alternatively you can just disable the protected mode by editing the Redis configuration file, and setting the protected mode option to 'no', and then restarting the server. 3) If you started the server manually just for testing, restart it with the '--protected-mode no' option. 4) Setup a bind address or an authentication password. NOTE: You only need to do one of the above things in order for the server to start accepting connections from the outside.

at redis.protocol$read_error_reply.invoke(protocol.clj:86)
at redis.protocol$read_reply.invoke(protocol.clj:119)
at redis.connection$send_command_and_read_reply.invoke(connection.clj:42)
at redis.connection$make_connection.invoke(connection.clj:75)
at redis.connection_pool$make_connection_factory$reify__495.makeObject(connection_pool.clj:21)
at org.apache.commons.pool.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:1190)
at redis.connection_pool.ConnectionPool.get_connection(connection_pool.clj:11)
at setup.core$do_new_setup.invoke(core.clj:211)
at setup.core$_main.doInvoke(core.clj:284)
at clojure.lang.RestFn.invoke(RestFn.java:436)
at clojure.lang.Var.invoke(Var.java:388)
at user$eval5.invoke(form-init4687907619169214448.clj:1)
at clojure.lang.Compiler.eval(Compiler.java:6782)
at clojure.lang.Compiler.eval(Compiler.java:6772)
at clojure.lang.Compiler.load(Compiler.java:7227)
... 11 more
REDIS.CONF:

bind 127.0.0.1
protected-mode no
port 6379
tcp-backlog 511
timeout 0
tcp-keepalive 300
daemonize no
supervised no
pidfile /var/run/redis_6379.pid
loglevel notice
logfile ""
databases 16
save 900 1
save 300 10
save 60 10000
stop-writes-on-bgsave-error yes
rdbcompression yes
rdbchecksum yes
dbfilename dump.rdb
dir ./
slave-serve-stale-data yes
slave-read-only yes
repl-diskless-sync no
repl-diskless-sync-delay 5
repl-disable-tcp-nodelay no
slave-priority 100
appendonly no
appendfilename "appendonly.aof"
appendfsync everysec
no-appendfsync-on-rewrite no
auto-aof-rewrite-percentage 100
auto-aof-rewrite-min-size 64mb
aof-load-truncated yes
lua-time-limit 5000
slowlog-log-slower-than 10000
slowlog-max-len 128
latency-monitor-threshold 0
notify-keyspace-events ""
hash-max-ziplist-entries 512
hash-max-ziplist-value 64
list-max-ziplist-size -2
list-compress-depth 0
set-max-intset-entries 512
zset-max-ziplist-entries 128
zset-max-ziplist-value 64
hll-sparse-max-bytes 300
activerehashing yes
client-output-buffer-limit normal 0 0 0
client-output-buffer-limit slave 256mb 64mb 60
client-output-buffer-limit pubsub 32mb 8mb 60
hz 10
aof-rewrite-incremental-fsync yes

非常感谢您的帮助。谢谢。

我认为您应该参考您的配置文件

26399:C 16 Jan 08:51:13.413 # Warning: no config file specified, using the default config. In order to specify a config file use ./redis-server /path/to/redis.conf
您可以尝试像这样启动redis服务器

./redis-server /path/to/redis-stable/redis.conf

您是否尝试过异常中给出的步骤?我想,这样做本身就能解决问题。在更改redis.conf后重新启动服务器吗?运行Redis的命令是什么?@KarthikeyanGopall和Pascal Le Merrer:谢谢你们两位的快速回复。是的,我尝试了第二步更改“redis.conf”,然后重新启动服务器。但redis似乎没有查看该文件。然后在启动redis时,我在脚本中手动给出了配置文件的路径,然后它就工作了。谢谢你的回答。然而,我现在不做那个项目。所以,我不能尝试你的方式。但是你的回答会对某人有所帮助。:-)