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
d5d23dab
Commit
d5d23dab
authored
May 28, 2010
by
antirez
Browse files
redis.conf new features the new option, a minor typo preventing the compilation fixed
parent
b0bd87f6
Changes
2
Hide whitespace changes
Inline
Side-by-side
redis.c
View file @
d5d23dab
...
@@ -1386,7 +1386,7 @@ void backgroundRewriteDoneHandler(int statloc) {
...
@@ -1386,7 +1386,7 @@ void backgroundRewriteDoneHandler(int statloc) {
/* If append only is actually enabled... */
/* If append only is actually enabled... */
close
(
server
.
appendfd
);
close
(
server
.
appendfd
);
server
.
appendfd
=
fd
;
server
.
appendfd
=
fd
;
if
(
appendfsync
!=
APPENDFSYNC_NO
)
aof_fsync
(
fd
);
if
(
server
.
appendfsync
!=
APPENDFSYNC_NO
)
aof_fsync
(
fd
);
server
.
appendseldb
=
-
1
;
/* Make sure it will issue SELECT */
server
.
appendseldb
=
-
1
;
/* Make sure it will issue SELECT */
redisLog
(
REDIS_NOTICE
,
"The new append only file was selected for future appends."
);
redisLog
(
REDIS_NOTICE
,
"The new append only file was selected for future appends."
);
}
else
{
}
else
{
...
...
redis.conf
View file @
d5d23dab
...
@@ -195,6 +195,26 @@ appendonly no
...
@@ -195,6 +195,26 @@ appendonly no
appendfsync
everysec
appendfsync
everysec
# appendfsync no
# appendfsync no
# When the AOF fsync policy is set to always or everysec, and a background
# saving process (a background save or AOF log background rewriting) is
# performing a lot of I/O against the disk, in some Linux configurations
# Redis may block too long on the fsync() call. Note that there is no fix for
# this currently, as even performing fsync in a different thread will block
# our synchronous write(2) call.
#
# In order to mitigate this problem it's possible to use the following option
# that will prevent fsync() from being called in the main process while a
# BGSAVE or BGREWRITEAOF is in progress.
#
# This means that while another child is saving the durability of Redis is
# the same as "appendfsync none", that in pratical terms means that it is
# possible to lost up to 30 seconds of log in the worst scenario (with the
# default Linux settings).
#
# If you have latency problems turn this to "yes". Otherwise leave it as
# "no" that is the safest pick from the point of view of durability.
no
-
appendfsync
-
on
-
rewrite
no
################################ VIRTUAL MEMORY ###############################
################################ VIRTUAL MEMORY ###############################
# Virtual Memory allows Redis to work with datasets bigger than the actual
# Virtual Memory allows Redis to work with datasets bigger than the actual
...
...
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