summaryrefslogtreecommitdiff
path: root/extra
diff options
context:
space:
mode:
authorThirunarayanan Balathandayuthapani <thiru@mariadb.com>2019-12-23 12:27:41 +0530
committerThirunarayanan Balathandayuthapani <thiru@mariadb.com>2019-12-23 15:51:02 +0530
commitbba59abb039fee1a3ee72a25643ebb7a0b64f3c5 (patch)
tree7a61982143377107d206fd7132bacfa39d2d6ce8 /extra
parenta59a015a75146ef486137de96e7a29a7eaf96a01 (diff)
downloadmariadb-git-bba59abb039fee1a3ee72a25643ebb7a0b64f3c5.tar.gz
MDEV-19176 Reduce the memory usage during recovery
- Moved the recv_sys->heap memory condition inside recv_parse_log_recs(). So that, InnoDB can mark the status as STORE_NO earlier. - InnoDB uses one third of buffer pool chunk size for reading the redo log records. In that case, we can avoid the scenario where buffer ran out of memory issue during recovery.
Diffstat (limited to 'extra')
-rw-r--r--extra/mariabackup/xtrabackup.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/extra/mariabackup/xtrabackup.cc b/extra/mariabackup/xtrabackup.cc
index e497ba5a972..73318d121fd 100644
--- a/extra/mariabackup/xtrabackup.cc
+++ b/extra/mariabackup/xtrabackup.cc
@@ -2686,7 +2686,9 @@ static lsn_t xtrabackup_copy_log(lsn_t start_lsn, lsn_t end_lsn, bool last)
}
}
- if (more_data && recv_parse_log_recs(0, STORE_NO, false)) {
+ store_t store = STORE_NO;
+
+ if (more_data && recv_parse_log_recs(0, &store, 0, false)) {
msg("Error: copying the log failed");