From 8686071c7f6c806e088cacc150ee7a07f309d8a156a285f8b85d77e4db70c37e Mon Sep 17 00:00:00 2001 From: Gang He Date: Wed, 29 May 2019 06:30:14 +0000 Subject: [PATCH 1/3] Accepting request 706184 from home:hmzhao:branches:openSUSE:Factory - Fix devices drop open error message (bsc#1122666) + bug-1122666_devices-drop-open-error-message.patch - Fix devices drop open error message (bsc#1122666) + bug-1122666_devices-drop-open-error-message.patch - Fix devices drop open error message (bsc#1122666) + bug-1122666_devices-drop-open-error-message.patch OBS-URL: https://build.opensuse.org/request/show/706184 OBS-URL: https://build.opensuse.org/package/show/Base:System/lvm2?expand=0&rev=240 --- ...2666_devices-drop-open-error-message.patch | 31 +++++++++++++++++++ device-mapper.changes | 6 ++++ device-mapper.spec | 2 ++ lvm2-clvm.changes | 6 ++++ lvm2-clvm.spec | 2 ++ lvm2.changes | 6 ++++ lvm2.spec | 2 ++ 7 files changed, 55 insertions(+) create mode 100644 bug-1122666_devices-drop-open-error-message.patch diff --git a/bug-1122666_devices-drop-open-error-message.patch b/bug-1122666_devices-drop-open-error-message.patch new file mode 100644 index 0000000..2dd15ce --- /dev/null +++ b/bug-1122666_devices-drop-open-error-message.patch @@ -0,0 +1,31 @@ +From 559cf0cd1e226baf63a98c39572264fbf5c3f6b4 Mon Sep 17 00:00:00 2001 +From: David Teigland +Date: Tue, 23 Apr 2019 09:39:42 -0500 +Subject: [PATCH] devices: drop open error message + +This open error is being printed in more common, +non-error circumstances than expected. After a +number of complaints make it only a debug message. +--- + lib/device/dev-io.c | 5 +---- + 1 file changed, 1 insertion(+), 4 deletions(-) + +diff --git a/lib/device/dev-io.c b/lib/device/dev-io.c +index 2a83a9657..6996a44dc 100644 +--- a/lib/device/dev-io.c ++++ b/lib/device/dev-io.c +@@ -572,10 +572,7 @@ int dev_open_flags(struct device *dev, int flags, int direct, int quiet) + } + } + #endif +- if (quiet) +- log_sys_debug("open", name); +- else +- log_sys_error("open", name); ++ log_sys_debug("open", name); + + dev->flags |= DEV_OPEN_FAILURE; + return 0; +-- +2.21.0 + diff --git a/device-mapper.changes b/device-mapper.changes index 49fe054..1a605a7 100644 --- a/device-mapper.changes +++ b/device-mapper.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com + +- Fix devices drop open error message (bsc#1122666) + + bug-1122666_devices-drop-open-error-message.patch + ------------------------------------------------------------------- Tue Mar 19 12:02:02 UTC 2019 - Martin Liška diff --git a/device-mapper.spec b/device-mapper.spec index 69e7162..7d00d41 100644 --- a/device-mapper.spec +++ b/device-mapper.spec @@ -51,6 +51,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build ### COMMON-PATCH-BEGIN ### # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch +Patch0002: bug-1122666_devices-drop-open-error-message.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -72,6 +73,7 @@ Programs and man pages for configuring and using the device mapper. %setup -q -n LVM2.%{lvm2_version} ### COMMON-PREP-BEGIN ### %patch0001 -p1 +%patch0002 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1 diff --git a/lvm2-clvm.changes b/lvm2-clvm.changes index 49fe054..1a605a7 100644 --- a/lvm2-clvm.changes +++ b/lvm2-clvm.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com + +- Fix devices drop open error message (bsc#1122666) + + bug-1122666_devices-drop-open-error-message.patch + ------------------------------------------------------------------- Tue Mar 19 12:02:02 UTC 2019 - Martin Liška diff --git a/lvm2-clvm.spec b/lvm2-clvm.spec index d040679..5283c5f 100644 --- a/lvm2-clvm.spec +++ b/lvm2-clvm.spec @@ -59,6 +59,7 @@ Provides: cmirrord = %{version} ### COMMON-PATCH-BEGIN ### # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch +Patch0002: bug-1122666_devices-drop-open-error-message.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -84,6 +85,7 @@ A daemon for using LVM2 Logival Volumes in a clustered environment. ### COMMON-PREP-BEGIN ### %patch0001 -p1 +%patch0002 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1 diff --git a/lvm2.changes b/lvm2.changes index 49fe054..1a605a7 100644 --- a/lvm2.changes +++ b/lvm2.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com + +- Fix devices drop open error message (bsc#1122666) + + bug-1122666_devices-drop-open-error-message.patch + ------------------------------------------------------------------- Tue Mar 19 12:02:02 UTC 2019 - Martin Liška diff --git a/lvm2.spec b/lvm2.spec index 6aa51ff..92cbb2d 100644 --- a/lvm2.spec +++ b/lvm2.spec @@ -61,6 +61,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build ### COMMON-PATCH-BEGIN ### # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch +Patch0002: bug-1122666_devices-drop-open-error-message.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -92,6 +93,7 @@ Volume Manager. %setup -q -n LVM2.%{version} ### COMMON-PREP-BEGIN ### %patch0001 -p1 +%patch0002 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1 From 64964ed048c1d5e7f84715369ebfbabfd904b843700f10b445115b1414a73c13 Mon Sep 17 00:00:00 2001 From: Gang He Date: Mon, 10 Jun 2019 05:11:11 +0000 Subject: [PATCH 2/3] Accepting request 708884 from home:hmzhao:branches:openSUSE:Factory - Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) - Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) - Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) OBS-URL: https://build.opensuse.org/request/show/708884 OBS-URL: https://build.opensuse.org/package/show/Base:System/lvm2?expand=0&rev=241 --- device-mapper.changes | 5 +++++ lvm.conf | 2 +- lvm2-clvm.changes | 5 +++++ lvm2.changes | 5 +++++ 4 files changed, 16 insertions(+), 1 deletion(-) diff --git a/device-mapper.changes b/device-mapper.changes index 1a605a7..357ddbc 100644 --- a/device-mapper.changes +++ b/device-mapper.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com + +- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) + ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com diff --git a/lvm.conf b/lvm.conf index 960c885..87c68cc 100644 --- a/lvm.conf +++ b/lvm.conf @@ -140,7 +140,7 @@ devices { # # This configuration option has an automatic default value. # filter = [ "a|.*/|" ] - filter = [ "r|/dev/.*/by-path/.*|", "r|/dev/.*/by-id/.*|", "r|/dev/fd.*|", "r|/dev/cdrom|", "a/.*/" ] + filter = [ "r|/dev/.*/by-path/.*|", "r|/dev/.*/by-id/.*|", "r|/dev/fd.*|", "r|/dev/cdrom|" ] # Configuration option devices/global_filter. # Limit the block devices that are used by LVM system components. diff --git a/lvm2-clvm.changes b/lvm2-clvm.changes index 1a605a7..357ddbc 100644 --- a/lvm2-clvm.changes +++ b/lvm2-clvm.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com + +- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) + ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com diff --git a/lvm2.changes b/lvm2.changes index 1a605a7..357ddbc 100644 --- a/lvm2.changes +++ b/lvm2.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com + +- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) + ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com From d1d2497104c6ac3d084265812e8e71d7db405ae7fe717fd5eef2e685c1333af3 Mon Sep 17 00:00:00 2001 From: Gang He Date: Thu, 27 Jun 2019 05:21:48 +0000 Subject: [PATCH 3/3] Accepting request 712184 from home:hmzhao:branches:openSUSE:Factory restore lvm.conf OBS-URL: https://build.opensuse.org/request/show/712184 OBS-URL: https://build.opensuse.org/package/show/Base:System/lvm2?expand=0&rev=242 --- ...ix-using-device-aliases-with-lvmetad.patch | 35 +++++++++++++++++++ device-mapper.changes | 5 +-- device-mapper.spec | 2 ++ lvm.conf | 2 +- lvm2-clvm.changes | 5 +-- lvm2-clvm.spec | 2 ++ lvm2.changes | 5 +-- lvm2.spec | 2 ++ 8 files changed, 51 insertions(+), 7 deletions(-) create mode 100644 bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch diff --git a/bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch b/bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch new file mode 100644 index 0000000..1bb5af4 --- /dev/null +++ b/bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch @@ -0,0 +1,35 @@ +From b13ebfa4c289a5bc6eb4f8ba26126db8e6d78296 Mon Sep 17 00:00:00 2001 +From: David Teigland +Date: Wed, 26 Jun 2019 16:03:42 -0500 +Subject: [PATCH] pvremove/vgextend: fix using device aliases with lvmetad + +These commands were looking for the requested device alias +before dev_cache_scan had created the list of devs on the +system, so they would fail and report the dev wasn't found. +--- + tools/toollib.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/tools/toollib.c b/tools/toollib.c +index 3221e5f1ca..1b01cccfa2 100644 +--- a/tools/toollib.c ++++ b/tools/toollib.c +@@ -5543,6 +5543,15 @@ int pvcreate_each_device(struct cmd_context *cmd, + + lvmcache_label_scan(cmd); + ++ /* ++ * When using lvmetad, we want to do a dev cache scan here (if not done ++ * already) so that the dev_cache_get just below will be able to find ++ * device aliases. When not using lvmetad, the label_scan just above ++ * has done dev_cache_scan, and this will not be run. ++ */ ++ if (!dev_cache_has_scanned()) ++ dev_cache_scan(); ++ + /* + * Translate arg names into struct device's. + */ +-- +2.21.0 + diff --git a/device-mapper.changes b/device-mapper.changes index 357ddbc..7aadbd9 100644 --- a/device-mapper.changes +++ b/device-mapper.changes @@ -1,7 +1,8 @@ ------------------------------------------------------------------- -Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com +Thu Jun 27 02:53:03 UTC 2019 - heming.zhao@suse.com -- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) +- Fix using device aliases with lvmetad (bsc#1137296) + + bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com diff --git a/device-mapper.spec b/device-mapper.spec index 7d00d41..67fef16 100644 --- a/device-mapper.spec +++ b/device-mapper.spec @@ -52,6 +52,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch Patch0002: bug-1122666_devices-drop-open-error-message.patch +Patch0003: bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -74,6 +75,7 @@ Programs and man pages for configuring and using the device mapper. ### COMMON-PREP-BEGIN ### %patch0001 -p1 %patch0002 -p1 +%patch0003 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1 diff --git a/lvm.conf b/lvm.conf index 87c68cc..960c885 100644 --- a/lvm.conf +++ b/lvm.conf @@ -140,7 +140,7 @@ devices { # # This configuration option has an automatic default value. # filter = [ "a|.*/|" ] - filter = [ "r|/dev/.*/by-path/.*|", "r|/dev/.*/by-id/.*|", "r|/dev/fd.*|", "r|/dev/cdrom|" ] + filter = [ "r|/dev/.*/by-path/.*|", "r|/dev/.*/by-id/.*|", "r|/dev/fd.*|", "r|/dev/cdrom|", "a/.*/" ] # Configuration option devices/global_filter. # Limit the block devices that are used by LVM system components. diff --git a/lvm2-clvm.changes b/lvm2-clvm.changes index 357ddbc..7aadbd9 100644 --- a/lvm2-clvm.changes +++ b/lvm2-clvm.changes @@ -1,7 +1,8 @@ ------------------------------------------------------------------- -Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com +Thu Jun 27 02:53:03 UTC 2019 - heming.zhao@suse.com -- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) +- Fix using device aliases with lvmetad (bsc#1137296) + + bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com diff --git a/lvm2-clvm.spec b/lvm2-clvm.spec index 5283c5f..8f8581a 100644 --- a/lvm2-clvm.spec +++ b/lvm2-clvm.spec @@ -60,6 +60,7 @@ Provides: cmirrord = %{version} # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch Patch0002: bug-1122666_devices-drop-open-error-message.patch +Patch0003: bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -86,6 +87,7 @@ A daemon for using LVM2 Logival Volumes in a clustered environment. ### COMMON-PREP-BEGIN ### %patch0001 -p1 %patch0002 -p1 +%patch0003 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1 diff --git a/lvm2.changes b/lvm2.changes index 357ddbc..7aadbd9 100644 --- a/lvm2.changes +++ b/lvm2.changes @@ -1,7 +1,8 @@ ------------------------------------------------------------------- -Thu Jun 6 07:55:00 UTC 2019 - heming.zhao@suse.com +Thu Jun 27 02:53:03 UTC 2019 - heming.zhao@suse.com -- Remove conflict filter in /etc/lvm/lvm.conf (bsc#1137296) +- Fix using device aliases with lvmetad (bsc#1137296) + + bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch ------------------------------------------------------------------- Tue Apr 30 10:20:05 UTC 2019 - ghe@suse.com diff --git a/lvm2.spec b/lvm2.spec index 92cbb2d..c1e48c6 100644 --- a/lvm2.spec +++ b/lvm2.spec @@ -62,6 +62,7 @@ BuildRoot: %{_tmppath}/%{name}-%{version}-build # Upstream patches Patch0001: bug-1114113_metadata-prevent-writing-beyond-metadata-area.patch Patch0002: bug-1122666_devices-drop-open-error-message.patch +Patch0003: bug-1137296_pvremove-vgextend-fix-using-device-aliases-with-lvmetad.patch # SUSE patches: 1000+ for LVM # Never upstream @@ -94,6 +95,7 @@ Volume Manager. ### COMMON-PREP-BEGIN ### %patch0001 -p1 %patch0002 -p1 +%patch0003 -p1 %patch1001 -p1 %patch1002 -p1 %patch1003 -p1