summaryrefslogtreecommitdiff
path: root/redis.conf
diff options
context:
space:
mode:
authorantirez <antirez@gmail.com>2010-02-10 15:59:09 +0100
committerantirez <antirez@gmail.com>2010-02-10 15:59:09 +0100
commitce8330208aacd63743ce706be020b5a7838f0a29 (patch)
treec87249bb38ea4783bd9633397642f01aa59eb598 /redis.conf
parent7c775e09433249e9d64c24ff92d2e5b716f5eb2d (diff)
downloadredis-ce8330208aacd63743ce706be020b5a7838f0a29.tar.gz
Saner VM defaults for redis.conf
Diffstat (limited to 'redis.conf')
-rw-r--r--redis.conf18
1 files changed, 9 insertions, 9 deletions
diff --git a/redis.conf b/redis.conf
index 0f5fe34ef..1c72bc4ae 100644
--- a/redis.conf
+++ b/redis.conf
@@ -203,11 +203,11 @@ vm-swap-file /tmp/redis-%p.vm
# RAM. Everything that deos not fit will be swapped on disk *if* possible, that
# is, if there is still enough contiguous space in the swap file.
#
-# With vm-max-memory 10000000 the system will swap almost everything it
-# can. Not a good default, just specify the max amount of RAM you can
-# in bytes, but it's better to leave some margin. For instance specify
-# an amount of RAM that's more or less 80% of your free RAM.
-vm-max-memory 10000000
+# With vm-max-memory 0 the system will swap everything it can. Not a good
+# default, just specify the max amount of RAM you can in bytes, but it's
+# better to leave some margin. For instance specify an amount of RAM
+# that's more or less between 60 and 80% of your free RAM.
+vm-max-memory 0
# Redis swap files is split into pages. An object can be saved using multiple
# contiguous pages, but pages can't be shared between different objects.
@@ -218,7 +218,7 @@ vm-max-memory 10000000
# If you use a lot of small objects, use a page size of 64 or 32 bytes.
# If you use a lot of big objects, use a bigger page size.
# If unsure, use the default :)
-vm-page-size 256
+vm-page-size 32
# Number of total memory pages in the swap file.
# Given that the page table (a bitmap of free/used pages) is taken in memory,
@@ -226,12 +226,12 @@ vm-page-size 256
#
# The total swap size is vm-page-size * vm-pages
#
-# With the default of 256-bytes memory pages and 104857600 pages Redis will
-# use a 25 GB swap file, that will use roughly 13 MB of RAM for the page table.
+# With the default of 32-bytes memory pages and 134217728 pages Redis will
+# use a 4 GB swap file, that will use 16 MB of RAM for the page table.
#
# It's better to use the smallest acceptable value for your application,
# but the default is large in order to work in most conditions.
-vm-pages 104857600
+vm-pages 134217728
# Max number of VM I/O threads running at the same time.
# This threads are used to read/write data from/to swap file, since they