From af4298464d6809969eb35382b3cbbb1ea0b3bd1e Mon Sep 17 00:00:00 2001 From: Jason Dillaman Date: Tue, 15 May 2018 15:07:21 -0400 Subject: [PATCH] librbd: deep-copy should remove parent metadata if overlap updated Signed-off-by: Jason Dillaman --- src/librbd/deep_copy/SetHeadRequest.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/librbd/deep_copy/SetHeadRequest.cc b/src/librbd/deep_copy/SetHeadRequest.cc index cab319820c1..ade87ba384d 100644 --- a/src/librbd/deep_copy/SetHeadRequest.cc +++ b/src/librbd/deep_copy/SetHeadRequest.cc @@ -102,7 +102,8 @@ template void SetHeadRequest::send_remove_parent() { m_image_ctx->parent_lock.get_read(); if (m_image_ctx->parent_md.spec.pool_id == -1 || - m_image_ctx->parent_md.spec == m_parent_spec) { + (m_image_ctx->parent_md.spec == m_parent_spec && + m_image_ctx->parent_md.overlap == m_parent_overlap)) { m_image_ctx->parent_lock.put_read(); send_set_parent(); return;