diff --git a/Fix-no-bitmap-allocate-for-stacked-res.patch b/Fix-no-bitmap-allocate-for-stacked-res.patch deleted file mode 100644 index 3a3d291..0000000 --- a/Fix-no-bitmap-allocate-for-stacked-res.patch +++ /dev/null @@ -1,108 +0,0 @@ -From b5eab810ded459792c24a4bc5db5ce272ea1ee15 Mon Sep 17 00:00:00 2001 -From: Philipp Reisner -Date: Fri, 26 Jan 2018 16:09:01 +0100 -Subject: [PATCH] v9,drbdadm,stacking: Fix setting the disk in stacked host -sections - -This got broken on the long way from drbd-8.4 to 9. ---- - -diff --git a/user/v9/drbdadm_postparse.c b/user/v9/drbdadm_postparse.c -index 1cefd5c2..b9e90de8 100644 ---- a/user/v9/drbdadm_postparse.c -+++ b/user/v9/drbdadm_postparse.c -@@ -493,9 +493,9 @@ void set_peer_in_resource(struct d_resource* res, int peer_required) - add_no_bitmap_opt(res); - } - --void set_disk_in_res(struct d_resource *res) -+void set_stacked_disk_in_res(struct d_resource *res) - { -- struct d_host_info *host; -+ struct d_host_info *host, *lower_host; - struct d_volume *a, *b; - - if (res->ignore) -@@ -505,41 +505,39 @@ void set_disk_in_res(struct d_resource *res) - if (!host->lower) - continue; - -- if (host->lower->ignore) -- continue; -- -- check_volume_sets_equal(res, host, host->lower->me); -- if (!config_valid) -- /* don't even bother for broken config. */ -- continue; -+ for_each_host(lower_host, &host->lower->all_hosts) { -+ check_volume_sets_equal(res, host, lower_host); -+ if (!config_valid) -+ /* don't even bother for broken config. */ -+ continue; - -- /* volume lists are sorted on vnr */ -- a = STAILQ_FIRST(&host->volumes); -- b = STAILQ_FIRST(&host->lower->me->volumes); -- while (a) { -- while (b && a->vnr > b->vnr) { -- /* Lower resource has more volumes. -- * Probably unusual, but we decided -- * that it should be legal. -- * Skip those that do not match */ -- b = STAILQ_NEXT(b, link); -- } -- if (a && b && a->vnr == b->vnr) { -- if (b->device) -- m_asprintf(&a->disk, "%s", b->device); -- else -- m_asprintf(&a->disk, "/dev/drbd%u", b->device_minor); -- /* stacked implicit volumes need internal meta data, too */ -- if (!a->meta_disk) -- m_asprintf(&a->meta_disk, "internal"); -- if (!a->meta_index) -- m_asprintf(&a->meta_index, "internal"); -- a = STAILQ_NEXT(a, link); -- b = STAILQ_NEXT(b, link); -- } else { -- /* config_invalid should have been set -- * by check_volume_sets_equal */ -- assert(0); -+ a = STAILQ_FIRST(&host->volumes); -+ b = STAILQ_FIRST(&lower_host->volumes); -+ while (a) { -+ while (b && a->vnr > b->vnr) { -+ /* Lower resource has more volumes. -+ * Probably unusual, but we decided -+ * that it should be legal. -+ * Skip those that do not match */ -+ b = STAILQ_NEXT(b, link); -+ } -+ if (a && b && a->vnr == b->vnr) { -+ if (b->device) -+ m_asprintf(&a->disk, "%s", b->device); -+ else -+ m_asprintf(&a->disk, "/dev/drbd%u", b->device_minor); -+ /* stacked implicit volumes need internal meta data, too */ -+ if (!a->meta_disk) -+ m_asprintf(&a->meta_disk, "internal"); -+ if (!a->meta_index) -+ m_asprintf(&a->meta_index, "internal"); -+ a = STAILQ_NEXT(a, link); -+ b = STAILQ_NEXT(b, link); -+ } else { -+ /* config_invalid should have been set -+ * by check_volume_sets_equal */ -+ assert(0); -+ } - } - } - } -@@ -1140,7 +1138,7 @@ void post_parse(struct resources *resources, enum pp_flags flags) - // Needs "me" set already - for_each_resource(res, resources) - if (res->stacked_on_one) -- set_disk_in_res(res); -+ set_stacked_disk_in_res(res); - - for_each_resource(res, resources) - fixup_peer_devices(res); diff --git a/Support-pass-force-to-dump-md.patch b/Support-pass-force-to-dump-md.patch deleted file mode 100644 index 4528660..0000000 --- a/Support-pass-force-to-dump-md.patch +++ /dev/null @@ -1,48 +0,0 @@ -drbdadm : Support pass force option to dump md - -At least till v8.9.6, drbdadm dump-md support -"--force" option to dump the metadata (might -stale) while the device still running. - -drbdmeta still able to dump but drbdadm -will show "unrecognized option" - -diff -Naur drbd-utils-9.0.0.orig/user/v9/config_flags.c drbd-utils-9.0.0/user/v9/config_flags.c ---- drbd-utils-9.0.0.orig/user/v9/config_flags.c 2018-01-25 10:49:04.419550855 +0800 -+++ drbd-utils-9.0.0/user/v9/config_flags.c 2018-01-25 10:51:53.412986007 +0800 -@@ -1081,6 +1081,12 @@ - { } }, - }; - -+struct context_def dump_md_ctx = { -+ .fields = { -+ { .name = "force", .argument_is_optional = true }, -+ { } }, -+}; -+ - struct context_def adjust_ctx = { - .fields = { - { "skip-disk", .argument_is_optional = true }, -diff -Naur drbd-utils-9.0.0.orig/user/v9/config_flags.h drbd-utils-9.0.0/user/v9/config_flags.h ---- drbd-utils-9.0.0.orig/user/v9/config_flags.h 2018-01-25 10:49:04.419550855 +0800 -+++ drbd-utils-9.0.0/user/v9/config_flags.h 2018-01-25 10:51:37.420850181 +0800 -@@ -100,6 +100,7 @@ - extern struct context_def device_options_ctx; - extern struct context_def invalidate_ctx; - extern struct context_def create_md_ctx; -+extern struct context_def dump_md_ctx; - extern struct context_def adjust_ctx; - extern struct context_def peer_device_options_ctx; - extern struct context_def handlers_ctx; -diff -Naur drbd-utils-9.0.0.orig/user/v9/drbdadm_main.c drbd-utils-9.0.0/user/v9/drbdadm_main.c ---- drbd-utils-9.0.0.orig/user/v9/drbdadm_main.c 2018-01-25 10:49:04.419550855 +0800 -+++ drbd-utils-9.0.0/user/v9/drbdadm_main.c 2018-01-25 10:49:44.659892592 +0800 -@@ -357,7 +357,7 @@ - static struct adm_cmd create_md_cmd = {"create-md", adm_create_md, &create_md_ctx, ACF1_MINOR_ONLY }; - static struct adm_cmd show_gi_cmd = {"show-gi", adm_setup_and_meta, ACF1_PEER_DEVICE .disk_required = 1}; - static struct adm_cmd get_gi_cmd = {"get-gi", adm_setup_and_meta, ACF1_PEER_DEVICE .disk_required = 1}; --static struct adm_cmd dump_md_cmd = {"dump-md", adm_drbdmeta, ACF1_MINOR_ONLY }; -+static struct adm_cmd dump_md_cmd = {"dump-md", adm_drbdmeta, &dump_md_ctx, ACF1_MINOR_ONLY }; - static struct adm_cmd wipe_md_cmd = {"wipe-md", adm_drbdmeta, ACF1_MINOR_ONLY }; - static struct adm_cmd apply_al_cmd = {"apply-al", adm_drbdmeta, ACF1_MINOR_ONLY }; - static struct adm_cmd forget_peer_cmd = {"forget-peer", adm_forget_peer, ACF1_DISCONNECT }; diff --git a/_service b/_service index 469e04d..9ec2bc1 100644 --- a/_service +++ b/_service @@ -5,10 +5,10 @@ drbd-utils - 9.2.0+git.%h + 9.3.1+git.%h master diff --git a/drbd-utils-9.2.0.tar.gz b/drbd-utils-9.2.0.tar.gz deleted file mode 100644 index 6a177c9..0000000 --- a/drbd-utils-9.2.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:11299b555b703440ef0af2c74b69cf6dfb833e050b87cfdc3b93d0b71d8820a6 -size 958084 diff --git a/drbd-utils-9.3.1.tar.gz b/drbd-utils-9.3.1.tar.gz new file mode 100644 index 0000000..27e434c --- /dev/null +++ b/drbd-utils-9.3.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9c5bcb496f3822c05762a3c6b59dede71e92a8227b76fb4de6362db7f0608747 +size 1054545 diff --git a/drbd-utils.changes b/drbd-utils.changes index 7308c88..9eb3c5d 100644 --- a/drbd-utils.changes +++ b/drbd-utils.changes @@ -1,3 +1,19 @@ +------------------------------------------------------------------- +Sun Apr 8 02:43:23 UTC 2018 - nwang@suse.com + +- bsc#1090167, Update to 9.3.1 + * update to Japanese man pages + * fixes for stacking in drbd-9.0 + * fixes for proxy support in drbd-9.0 + * fix adjusting --bitmap=no peer to diskfull + * VCS: typos and fixes for stacked resources +- Remove upstream patch Fix-no-bitmap-allocate-for-stacked-res.patch +- Remove upstream patch Support-pass-force-to-dump-md.patch +- Remove patch fix-segfault-up-stacked-resource.patch with + upstream fix 74b1cbb274 +- drbdadm v84: fixup for disable-write-same +- Fix IPv4 & IPv6 address comparisons for 'drbdadm adjust' + ------------------------------------------------------------------- Mon Feb 5 07:09:33 UTC 2018 - nwang@suse.com diff --git a/drbd-utils.spec b/drbd-utils.spec index 77e6108..3156ed3 100644 --- a/drbd-utils.spec +++ b/drbd-utils.spec @@ -19,7 +19,7 @@ %bcond_without drbdmon Name: drbd-utils -Version: 9.2.0 +Version: 9.3.1 Release: 0 Summary: Distributed Replicated Block Device License: GPL-2.0+ @@ -31,14 +31,11 @@ Source: http://www.drbd.org/download/drbd/utils/%{name}-%{version}.tar.g Patch1: init-script-fixes.diff Patch2: fix-libdir-in-Makefile.patch Patch3: fence-after-pacemaker-down.patch -Patch4: fix-segfault-up-stacked-resource.patch # PATCH-SUSE-FIX: Disable quorum in default configuration (bsc#1032142) -Patch5: 0001-Disable-quorum-in-default-configuration-bsc-1032142.patch -Patch6: fix_call_khelper_with_stack.patch -Patch7: move_fencing_from_disk_to_net_in_example.patch -Patch8: skip_sh-b-pri_in_v9.patch -Patch9: Fix-no-bitmap-allocate-for-stacked-res.patch -Patch10: Support-pass-force-to-dump-md.patch +Patch4: 0001-Disable-quorum-in-default-configuration-bsc-1032142.patch +Patch5: fix_call_khelper_with_stack.patch +Patch6: move_fencing_from_disk_to_net_in_example.patch +Patch7: skip_sh-b-pri_in_v9.patch Provides: drbd-bash-completion = %{version} Provides: drbd-pacemaker = %{version} @@ -88,9 +85,6 @@ raid 1. It is a building block for setting up clusters. %patch5 -p1 %patch6 -p1 %patch7 -p1 -%patch8 -p1 -%patch9 -p1 -%patch10 -p1 %build export WANT_DRBD_REPRODUCIBLE_BUILD=1 diff --git a/fix-segfault-up-stacked-resource.patch b/fix-segfault-up-stacked-resource.patch deleted file mode 100644 index 5878c58..0000000 --- a/fix-segfault-up-stacked-resource.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff -Naur drbd-utils-8.9.6.orig/user/v9/drbdadm.h drbd-utils-8.9.6/user/v9/drbdadm.h ---- drbd-utils-8.9.6.orig/user/v9/drbdadm.h 2016-06-23 18:20:40.608796513 +0800 -+++ drbd-utils-8.9.6/user/v9/drbdadm.h 2016-06-23 18:21:18.828684887 +0800 -@@ -388,6 +388,7 @@ - extern void global_validate_maybe_expand_die_if_invalid(int expand, enum pp_flags flags); - extern struct d_option *new_opt(char *name, char *value); - extern int hostname_in_list(const char *name, struct names *names); -+extern bool hostnames_equal(const char *a, const char *b); - extern char *_names_to_str(char* buffer, struct names *names); - extern char *_names_to_str_c(char* buffer, struct names *names, char c); - #define NAMES_STR_SIZE 255 -diff -Naur drbd-utils-8.9.6.orig/user/v9/drbdadm_postparse.c drbd-utils-8.9.6/user/v9/drbdadm_postparse.c ---- drbd-utils-8.9.6.orig/user/v9/drbdadm_postparse.c 2016-06-23 18:20:40.608796513 +0800 -+++ drbd-utils-8.9.6/user/v9/drbdadm_postparse.c 2016-06-23 18:21:13.644700061 +0800 -@@ -98,6 +98,21 @@ - } - } - -+struct d_host_info *find_host_info_by_fakename(struct d_resource* res, char *name) -+{ -+ struct d_host_info *host; -+ char *concat_name; -+ -+ for_each_host(host, &res->all_hosts) { -+ concat_name = strdup(names_to_str_c(&host->on_hosts, '_')); -+ if (hostnames_equal(name, concat_name)) -+ return host; -+ } -+ -+ return NULL; -+} -+ -+ - struct d_host_info *find_host_info_by_name(struct d_resource* res, char *name) - { - struct d_host_info *host; -@@ -403,7 +418,11 @@ - if (conn->peer) { - host_info = conn->peer; - } else { -- host_info = find_host_info_by_name(res, candidate->name); -+ if (candidate->faked_hostname) { -+ host_info = find_host_info_by_fakename(res, candidate->name); -+ } else { -+ host_info = find_host_info_by_name(res, candidate->name); -+ } - conn->peer = host_info; - } - path->peer_address = candidate->address.addr ? &candidate->address : &host_info->address;