File keep-bitmap-in-create-md-kernel.patch of Package drbd.openSUSE_Leap_42.3_Update

diff -Naur drbd-9.0.6+git.08cda19.orig/drbd/drbd_main.c drbd-9.0.6+git.08cda19/drbd/drbd_main.c
--- drbd-9.0.6+git.08cda19.orig/drbd/drbd_main.c	2017-05-03 10:56:14.717392319 +0800
+++ drbd-9.0.6+git.08cda19/drbd/drbd_main.c	2017-05-03 17:50:02.633765417 +0800
@@ -4251,6 +4251,10 @@
 		/* maybe: for each bitmap_index != -1, create a connection object
 		 * with peer_node_id = i, unless already present. */
 	}
+
+	/*my own node id 's bitmap uuid should always be 0*/
+	bdev->md.peers[my_node_id].bitmap_uuid = 0;
+
 	BUILD_BUG_ON(ARRAY_SIZE(bdev->md.history_uuids) != ARRAY_SIZE(buffer->history_uuids));
 	for (i = 0; i < ARRAY_SIZE(buffer->history_uuids); i++)
 		bdev->md.history_uuids[i] = be64_to_cpu(buffer->history_uuids[i]);
openSUSE Build Service is sponsored by