From: Sage Weil Date: Tue, 9 Jul 2019 17:03:35 +0000 (-0500) Subject: osd/SnapMapper: reset iterators at finish of run() X-Git-Tag: v15.1.0~2249^2~1 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=f7607512fee4967e027337159cbd81d7bea86385;p=ceph-ci.git osd/SnapMapper: reset iterators at finish of run() These iterators implicitly hold locks in FileStore, which can lead to a deadlock if they are still alive and the caller tries to take new locks. Signed-off-by: Sage Weil --- diff --git a/src/osd/SnapMapper.cc b/src/osd/SnapMapper.cc index 02553af8e4b..b6eb7ec4b0a 100644 --- a/src/osd/SnapMapper.cc +++ b/src/osd/SnapMapper.cc @@ -623,6 +623,8 @@ void SnapMapper::Scrubber::run() } dout(10) << __func__ << " end, found " << stray.size() << " stray" << dendl; + psit = ObjectMap::ObjectMapIterator(); + mapit = ObjectMap::ObjectMapIterator(); }