日期:2014-05-16 浏览次数:20423 次
daemonize yes pidfile /var/run/redis-master.pid port 6379 timeout 0 loglevel verbose logfile stdout databases 16 save 60 100 rdbcompression yes dbfilename dump-master.rdb dir /usr/local/redis/data slave-serve-stale-data yes requirepass ooxxoo appendonly no appendfsync everysec no-appendfsync-on-rewrite no auto-aof-rewrite-percentage 100 auto-aof-rewrite-min-size 64mb slowlog-log-slower-than 10000 slowlog-max-len 128 maxclients 128 maxmemory 1gb vm-enabled no vm-swap-file /tmp/redis.swap vm-max-memory 0 vm-page-size 32 vm-pages 134217728 vm-max-threads 4 hash-max-zipmap-entries 512 hash-max-zipmap-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 activerehashing yes
daemonize no pidfile /var/run/redis-slave.pid port 7379 timeout 0 loglevel verbose logfile stdout databases 16 save 60 100 rdbcompression yes dbfilename dump-slave.rdb dir /usr/local/redis/data slave-serve-stale-data yes slaveof 127.0.0.1 6379 masterauth ooxxoo appendonly no appendfsync everysec no-appendfsync-on-rewrite no auto-aof-rewrite-percentage 100 auto-aof-rewrite-min-size 64mb slowlog-log-slower-than 10000 slowlog-max-len 128 maxclients 128 maxmemory 1gb vm-enabled no vm-swap-file /tmp/redis.swap vm-max-memory 0 vm-page-size 32 vm-pages 134217728 vm-max-threads 4 hash-max-zipmap-entries 512 hash-max-zipmap-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 activerehashing yes
WARNING overcommit_memory is set to 0! Background save may fail under low memory condition. To fix this issue add 'vm.overcommit_memory = 1' to /etc/sysctl.conf and then reboot or run the command 'sysctl vm.overcommit_memory=1' for this to take effect.
# echo vm.overcommit_memory=1 >> /etc/sysctl.conf # sysctl vm.overcommit_memory=1