From: Sage Weil Date: Wed, 11 Jul 2018 01:22:49 +0000 (-0500) Subject: osd/PG: do not blindly roll forward to log.head X-Git-Tag: v13.2.1~62^2~2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=c20987e49286dc8fee17d55f7559eaf12e20aba8;p=ceph.git osd/PG: do not blindly roll forward to log.head If we are told we can roll forward by the primary, we should only roll forward as far as the primary says we can. This probably came out of the similar case in append_log(), but notably that roll_forward() only happens if !transaction_applied (i.e., backfill target), and that condition is not checked here. Fixes: http://tracker.ceph.com/issues/24597 Signed-off-by: Sage Weil (cherry picked from commit 858ff647ff7bd1f6277823b5185ead5ffebc05b0) --- diff --git a/src/osd/PG.cc b/src/osd/PG.cc index c0c5bf9fd3b..faff080654a 100644 --- a/src/osd/PG.cc +++ b/src/osd/PG.cc @@ -5564,9 +5564,6 @@ bool PG::append_log_entries_update_missing( assert(entries.begin()->version > info.last_update); PGLogEntryHandler rollbacker{this, &t}; - if (roll_forward_to) { - pg_log.roll_forward(&rollbacker); - } bool invalidate_stats = pg_log.append_new_log_entries(info.last_backfill, info.last_backfill_bitwise,