]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
librbd: abort an image removal if block objects cannot be removed
authorJason Dillaman <dillaman@redhat.com>
Mon, 22 Jul 2019 13:48:26 +0000 (09:48 -0400)
committerJason Dillaman <dillaman@redhat.com>
Sun, 18 Aug 2019 20:47:02 +0000 (16:47 -0400)
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
(cherry picked from commit 361e51f3fb4f146048995e5adbeb8ff90685fc53)

src/librbd/image/RemoveRequest.cc

index 88af466615a5e24b7bc1c15a14f06c175d0a9952..1cff51b3eae5d777f9fa62079df35e3bfeb098e0 100644 (file)
@@ -149,8 +149,10 @@ void RemoveRequest<I>::handle_trim_image(int r) {
   ldout(m_cct, 20) << "r=" << r << dendl;
 
   if (r < 0) {
-    lderr(m_cct) << "warning: failed to remove some object(s): "
+    lderr(m_cct) << "failed to remove some object(s): "
                  << cpp_strerror(r) << dendl;
+    send_close_image(r);
+    return;
   }
 
   if (m_old_format) {