]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rbd-mirror: additional debugging messages for snapshot-based mirroring
authorJason Dillaman <dillaman@redhat.com>
Fri, 21 Feb 2020 18:37:49 +0000 (13:37 -0500)
committerJason Dillaman <dillaman@redhat.com>
Fri, 21 Feb 2020 18:37:49 +0000 (13:37 -0500)
Signed-off-by: Jason Dillaman <dillaman@redhat.com>
src/test/rbd_mirror/test_ImageReplayer.cc
src/tools/rbd_mirror/image_replayer/snapshot/ApplyImageStateRequest.cc

index fcd8db6da4e2f5cd79da72c33d7e2db9a0ec2017..83fd20f96ae9f0fe19f7fa0820605340e6760b03 100644 (file)
@@ -413,6 +413,8 @@ public:
     ASSERT_EQ(0, get_last_mirror_snapshot(m_remote_ioctx, m_remote_image_id,
                                           &remote_snap_id, &remote_mirror_ns));
 
+    std::cout << "remote_snap_id=" << remote_snap_id << std::endl;
+
     std::string local_image_id;
     ASSERT_EQ(0, librbd::cls_client::mirror_image_get_image_id(
                    &m_local_ioctx, m_global_image_id, &local_image_id));
@@ -434,6 +436,9 @@ public:
           local_mirror_ns.primary_mirror_uuid == m_remote_mirror_uuid &&
           local_mirror_ns.primary_snap_id == remote_snap_id &&
           local_mirror_ns.complete) {
+
+        std::cout << "local_snap_id=" << local_snap_id << ", "
+                  << "local_snap_ns=" << local_mirror_ns << std::endl;
         return;
       }
 
index 3d628efd710865d85838491e6d7f1228ef00db9d..6bceded0c5071bd7f34fd5b68e60136baca40c3b 100644 (file)
@@ -553,7 +553,7 @@ void ApplyImageStateRequest<I>::handle_rename_snapshot(int r) {
 
 template <typename I>
 void ApplyImageStateRequest<I>::set_snapshot_limit() {
-  dout(15) << dendl;
+  dout(15) << "snap_limit=" << m_image_state.snap_limit << dendl;
 
   // no need to even check the current limit -- just set it
   std::shared_lock owner_locker{m_local_image_ctx->owner_lock};