ef9089f4e8
Update to the head of the upstream staging branch * Patches 0005-0042 are from the upstream staging branch * Previous patches 0005 & 0006 are now patches 0023 & 0005 Rename redhat patches * Previous patches 0007-0017 are now patches 0043-0053 Change from using readline to libedit * readline is licensed GPL v3, and multipathd includes code licensed gpl v2. Remove README.alua * information moved to README.md
37 lines
1.3 KiB
Diff
37 lines
1.3 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Benjamin Marzinski <bmarzins@redhat.com>
|
|
Date: Tue, 9 Aug 2022 16:46:28 -0500
|
|
Subject: [PATCH] multipathd: Handle losing all path in update_map
|
|
|
|
Its possible that when a multipath device is being updated, it will end
|
|
up that all the paths for it are gone. This can happen if paths are
|
|
added and then removed again before multipathd processes the uevent for
|
|
the newly created multipath device. In this case multipathd wasn't
|
|
taking the proper action for the case where all the paths had been
|
|
removed. If flush_on_last_del was set, multipathd wasn't disabling
|
|
flushing and if deferred_remove was set, it wasn't doing a deferred
|
|
remove. Multipathd should call flush_map_nopaths(), just like
|
|
ev_remove_path() does when the last path is removed.
|
|
|
|
Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com>
|
|
Reviewed-by: Martin Wilck <mwilck@suse.com>
|
|
---
|
|
multipathd/main.c | 4 ++++
|
|
1 file changed, 4 insertions(+)
|
|
|
|
diff --git a/multipathd/main.c b/multipathd/main.c
|
|
index 3fcd6bdb..7d127dbe 100644
|
|
--- a/multipathd/main.c
|
|
+++ b/multipathd/main.c
|
|
@@ -602,6 +602,10 @@ retry:
|
|
goto fail;
|
|
}
|
|
verify_paths(mpp);
|
|
+ if (VECTOR_SIZE(mpp->paths) == 0 &&
|
|
+ flush_map_nopaths(mpp, vecs))
|
|
+ return 1;
|
|
+
|
|
mpp->action = ACT_RELOAD;
|
|
|
|
if (mpp->prflag) {
|