Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
f4da796c
Commit
f4da796c
authored
Mar 20, 2014
by
antirez
Browse files
Default LRU samples is now 5.
parent
c641b670
Changes
2
Hide whitespace changes
Inline
Side-by-side
redis.conf
View file @
f4da796c
...
@@ -419,12 +419,15 @@ slave-priority 100
...
@@ -419,12 +419,15 @@ slave-priority 100
# maxmemory-policy volatile-lru
# maxmemory-policy volatile-lru
# LRU and minimal TTL algorithms are not precise algorithms but approximated
# LRU and minimal TTL algorithms are not precise algorithms but approximated
# algorithms (in order to save memory), so you can
select as well the sample
# algorithms (in order to save memory), so you can
tune it for speed or
#
size to check. For instance f
or default Redis will check
thre
e keys and
#
accuracy. F
or default Redis will check
fiv
e keys and
pick the one that was
#
pick the one that was
used less recently, you can change the sample size
# used less recently, you can change the sample size
using the following
#
using the following
configuration directive.
# configuration directive.
#
#
# maxmemory-samples 3
# The default of 5 produces good enough results. 10 Approximates very closely
# true LRU but costs a bit more CPU. 3 is very fast but not very accurate.
#
# maxmemory-samples 5
############################## APPEND ONLY MODE ###############################
############################## APPEND ONLY MODE ###############################
...
...
src/redis.h
View file @
f4da796c
...
@@ -113,7 +113,7 @@
...
@@ -113,7 +113,7 @@
#define REDIS_DEFAULT_SLAVE_READ_ONLY 1
#define REDIS_DEFAULT_SLAVE_READ_ONLY 1
#define REDIS_DEFAULT_REPL_DISABLE_TCP_NODELAY 0
#define REDIS_DEFAULT_REPL_DISABLE_TCP_NODELAY 0
#define REDIS_DEFAULT_MAXMEMORY 0
#define REDIS_DEFAULT_MAXMEMORY 0
#define REDIS_DEFAULT_MAXMEMORY_SAMPLES
3
#define REDIS_DEFAULT_MAXMEMORY_SAMPLES
5
#define REDIS_DEFAULT_AOF_FILENAME "appendonly.aof"
#define REDIS_DEFAULT_AOF_FILENAME "appendonly.aof"
#define REDIS_DEFAULT_AOF_NO_FSYNC_ON_REWRITE 0
#define REDIS_DEFAULT_AOF_NO_FSYNC_ON_REWRITE 0
#define REDIS_DEFAULT_ACTIVE_REHASHING 1
#define REDIS_DEFAULT_ACTIVE_REHASHING 1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment