From 76a519b215e591e0948d627fb1de826ed0bf415d Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Thu, 31 Jul 2014 09:26:03 -0700 Subject: [PATCH] osd/ReplicatedPG: evict blindly if there is no hit_set If there is no hit set for a PG, blindly evict objects. This avoids an assert(hit_set) in agent_estimate_atime_temp(). Fixes: #8982 Signed-off-by: Sage Weil (cherry picked from commit ea4996d3ef15c5d5a776d162b08d9fad6859c976) --- src/osd/ReplicatedPG.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/osd/ReplicatedPG.cc b/src/osd/ReplicatedPG.cc index 4a2b740b9fdf..434f9dc24725 100644 --- a/src/osd/ReplicatedPG.cc +++ b/src/osd/ReplicatedPG.cc @@ -11313,7 +11313,8 @@ bool ReplicatedPG::agent_maybe_evict(ObjectContextRef& obc) } } - if (agent_state->evict_mode != TierAgentState::EVICT_MODE_FULL) { + if (agent_state->evict_mode != TierAgentState::EVICT_MODE_FULL && + hit_set) { // is this object old and/or cold enough? int atime = -1, temp = 0; agent_estimate_atime_temp(soid, &atime, NULL /*FIXME &temp*/); -- 2.47.3