1

我有一个使用 redis 和 sensu 的工作设置。突然我在尝试拍摄 RDB 快照时遇到了 redis 服务器问题。

[2830] 27 Dec 06:25:50.648 * 10000 changes in 60 seconds. Saving...
[2830] 27 Dec 06:25:50.649 * Background saving started by pid 24929
[24929] 27 Dec 06:25:50.670 # Error moving temp DB file on the final destination: Operation not permitted
[2830] 27 Dec 06:25:50.750 # Background saving error

我检查了redis dir路径并且写权限在那里。

这是我的redis conf。

Redis 配置文件示例
daemonize yes
port 6379
tcp-backlog 511
timeout 0
tcp-keepalive 0

loglevel debug
logfile "/var/log/redis/redis.log"

databases 1
####   save ""
save 9000 1
save 3000 10
save 60 10000

stop-writes-on-bgsave-error yes

rdbcompression yes
rdbchecksum yes

dbfilename dump.rdb
dir /var/redis/6379

slave-serve-stale-data yes
repl-disable-tcp-nodelay no
slave-priority 100
appendonly yes
appendfilename "appendonly.aof"
appendfsync everysec

no-appendfsync-on-rewrite no
auto-aof-rewrite-percentage 100
auto-aof-rewrite-min-size 64mb
lua-time-limit 5000
slowlog-log-slower-than 10000
slowlog-max-len 128
notify-keyspace-events ""
hash-max-ziplist-entries 512
hash-max-ziplist-value 64
list-max-ziplist-entries 512
list-max-ziplist-value 64

set-max-intset-entries 512
zset-max-ziplist-entries 128
zset-max-ziplist-value 64

hll-sparse-max-bytes 3000
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 
4

1 回答 1

-1

只有需要访问 Redis 的用户才有权读取其数据及其数据库。这是默认用户,用户 Redis。Redis 数据目录必须归 Redis 所有。

选项一(第 4、5、6、7、8 段)或选项二(第 6 步)

于 2015-12-30T19:49:07.760 回答