From 1ff47396e954edbc234c948e4e68ea5c116ff58550320cd6c13dc45a39643cce Mon Sep 17 00:00:00 2001 From: Martin Wilck Date: Mon, 25 Apr 2022 09:55:14 +0000 Subject: [PATCH] - If multipath-tools is newly installed, load dm-multipath (bsc#1196898) OBS-URL: https://build.opensuse.org/package/show/Base:System/multipath-tools?expand=0&rev=276 --- multipath-tools.changes | 6 ++++++ multipath-tools.spec | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/multipath-tools.changes b/multipath-tools.changes index 934e951..daad0b8 100644 --- a/multipath-tools.changes +++ b/multipath-tools.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Mon Mar 28 12:54:15 UTC 2022 - Martin Wilck + +- If multipath-tools is newly installed, load dm-multipath + (bsc#1196898) + ------------------------------------------------------------------- Wed Feb 16 13:24:47 UTC 2022 - Martin Wilck diff --git a/multipath-tools.spec b/multipath-tools.spec index 2f5ca73..742c08f 100644 --- a/multipath-tools.spec +++ b/multipath-tools.spec @@ -1,7 +1,7 @@ # # spec file for package multipath-tools # -# Copyright (c) 2021 SUSE LLC +# Copyright (c) 2022 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -81,6 +81,7 @@ availability of the map devices. + # Currently, it makes no sense to split out libmpathpersist and libmpathcmd # separately. libmultipath has no stable API at all, and it depends # on libmpathcmd (to be fixed). libmpathpersist depends on libmultipath @@ -193,6 +194,9 @@ install -m 644 -D %{SOURCE3} %{buildroot}/usr/lib/dracut/dracut.conf.d/dm-parts. %post [ -f /.buildenv ] && exit 0 %service_add_post multipathd.socket multipathd.service +if [ $1 -eq 1 ]; then + [ ! -x /sbin/modprobe ] || /sbin/modprobe dm_multipath || true +fi %{?regenerate_initrd_post} exit 0