Skip to content

Commit

Permalink
osdc: cache should ignore error bhs during trim
Browse files Browse the repository at this point in the history
A read error (such as injecting a timeout into an OSD op) might result
in a bh in an error state. These should be trimable by the cache.

Fixes: http://tracker.ceph.com/issues/18436
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 5910ed9)
  • Loading branch information
Jason Dillaman authored and smithfarm committed Feb 3, 2017
1 parent 83af8cd commit 750fa24
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/osdc/ObjectCacher.cc
Expand Up @@ -997,7 +997,7 @@ void ObjectCacher::trim()
break;

ldout(cct, 10) << "trim trimming " << *bh << dendl;
assert(bh->is_clean() || bh->is_zero());
assert(bh->is_clean() || bh->is_zero() || bh->is_error());

Object *ob = bh->ob;
bh_remove(ob, bh);
Expand Down

0 comments on commit 750fa24

Please sign in to comment.