Skip to content

Commit 442c3de

Browse files
committed
Limit max overage to 20% during RDB save
1 parent f747044 commit 442c3de

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/evict.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -423,7 +423,7 @@ int getMaxmemoryState(size_t *total, size_t *logical, size_t *tofree, float *lev
423423
if (fPreSnapshot)
424424
maxmemory = static_cast<size_t>(maxmemory * 0.9); // derate memory by 10% since we won't be able to free during snapshot
425425
if (g_pserver->FRdbSaveInProgress())
426-
maxmemory = static_cast<size_t>(maxmemory*1.5);
426+
maxmemory = static_cast<size_t>(maxmemory*1.2);
427427

428428
/* We may return ASAP if there is no need to compute the level. */
429429
int return_ok_asap = !maxmemory || mem_reported <= maxmemory;

0 commit comments

Comments
 (0)