If get_uid() is returning a different wwid in uev_update_path(), then
the uid_attribute must have already gotten updated, which was the
purpose behind calling rescan_path() in the first place.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipathd/main.c | 1 -
1 file
map removed, there's nothing to keep us from removing
the path.
Call set_path_removed() before update_mpp_paths() to avoid the odd case
of ev_remove_path() removing the map but not the path.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
libmultipath/structs_vec.c |
remove_map_and_stop_waiter() already calls orphan_paths() so flush_map()
doesn't need to call orphan_paths() before calling
remove_map_and_stop_waiter().
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git
to dereference the path after it was removed.
To deal with this, make ev_remove_path() return a different symbolic
value for each outcome, and make the callers react appropriately for
the different values. Found by coverity.
Signed-off-by: Benjamin Marzinski
---
multipathd/cli_handlers.c | 24
on Martin's suggestions about wwid change handling
in uev_update_path().
Changes from v1:
0001: changed comment based on Martin's suggestion
0004: moved location of atexit() call based on Martin's suggestion
0006: New patch, based on Martin's comments on patch 0003
Benjamin Marzinski (6
configure() can retry multiple times, each time reallocing a maps and
paths vector, and leaking the previous ones. Fix this by always freeing
the vectors before configure() exits. Found by coverity.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipath/main.c | 7 ++-
1
map removed, there's nothing to keep us from removing
the path.
Call set_path_removed() before update_mpp_paths() to avoid the odd case
of ev_remove_path() removing the map but not the path.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
libmultipath/structs_vec.c |
to dereference the path after it was removed.
To deal with this, make ev_remove_path() return a different symbolic
value for each outcome, and make the callers react appropriately for
the different values. Found by coverity.
Signed-off-by: Benjamin Marzinski
---
multipathd/cli_handlers.c | 14
configure() can retry multiple times, each time reallocing a maps and
paths vector, and leaking the previous ones. Fix this by always freeing
the vectors before configure() exits. Found by coverity.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipath/main.c | 7 ++-
1
If get_uid() is returning a different wwid in uev_update_path(), then
the uid_attribute must have already gotten updated, which was the
purpose behind calling rescan_path() in the first place.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff
remove_map_and_stop_waiter() already calls orphan_paths() so flush_map()
doesn't need to call orphan_paths() before calling
remove_map_and_stop_waiter().
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git
from v1:
0001: changed comment based on Martin's suggestion
0004: moved location of atexit() call based on Martin's suggestion
0006: New patch, based on Martin's comments on patch 0003
Benjamin Marzinski (6):
multipathd: don't fail to remove path once the map is removed
multipathd: remove
If a new block was allocated, but couldn't be filled, getblock will
discard it. When it does so, it needs to free the block to avoid leaking
memory. Found by coverity.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
kpartx/kpartx.c | 2 ++
1 file changed, 2 insertions(+)
diff
mory leak")
> Signed-off-by: Martin Wilck
Reviewed-by: Benjamin Marzinski
>
> ---
> v2: Use $(PKGCONFIG) (Ben Marzinski); remove "\n" in awk.
>
> ---
> multipathd/Makefile | 2 ++
> multipathd/main.c | 17 +++--
> 2 files changed, 17 insertions(+
On Thu, May 13, 2021 at 08:11:13PM +, Martin Wilck wrote:
> On Thu, 2021-05-13 at 12:23 -0500, Benjamin Marzinski wrote:
> > There are many possible outcomes of calling ev_remove_path(), and not
> > all callers agree on which outcomes are a success and which are a
remove_map_and_stop_waiter() already calls orphan_paths() so flush_map()
doesn't need to call orphan_paths() before calling
remove_map_and_stop_waiter().
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git
: changed comment based on Martin's suggestion
0004: moved location of atexit() call based on Martin's suggestion
0006: New patch, based on Martin's comments on patch 0003
Benjamin Marzinski (6):
multipathd: don't fail to remove path once the map is removed
multipathd: remove duplicate
to dereference the path after it was removed. Change
ev_remove_path() to return success whenever the path is removed, even if
the map was removed due to a failure when trying to reload it. Found by
coverity.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 6 --
1 file changed, 4 insertions
If a new block was allocated, but couldn't be filled, getblock will
discard it. When it does so, it needs to free the block to avoid leaking
memory. Found by coverity.
Signed-off-by: Benjamin Marzinski
Reviewed-by: Martin Wilck
---
kpartx/kpartx.c | 2 ++
1 file changed, 2 insertions(+)
diff
map removed, there's nothing to keep us from removing
the path.
Call set_path_removed() before update_mpp_paths() to avoid the odd case
of ev_remove_path() removing the map but not the path.
Signed-off-by: Benjamin Marzinski
---
libmultipath/structs_vec.c | 4 ++--
multipathd/main.c |
configure() can retry multiple times, each time reallocing a maps and
paths vector, and leaking the previous ones. Fix this by always freeing
the vectors before configure() exits. Found by coverity.
Signed-off-by: Benjamin Marzinski
---
multipath/main.c | 7 ++-
1 file changed, 6 insertions
There are many possible outcomes of calling ev_remove_path(), and not
all callers agree on which outcomes are a success and which are a
failure. So ev_remove_path() should simply return a different value for
each outcome, and the callers can decide how to deal with them.
Signed-off-by: Benjamin
On Wed, May 12, 2021 at 11:17:05PM +0200, mwi...@suse.com wrote:
> From: Martin Wilck
>
> To avoid race conditions with pending RCU callbacks on exit, it's
> necessary to call rcu_barrier() in cleanup_rcu() (see
> https://lists.lttng.org/pipermail/lttng-dev/2021-May/029958.html and
>
On Wed, May 12, 2021 at 08:36:49PM +, Martin Wilck wrote:
> On Wed, 2021-05-12 at 14:53 -0500, Benjamin Marzinski wrote:
> > On Wed, May 12, 2021 at 11:38:08AM +, Martin Wilck wrote:
> > > On Tue, 2021-05-11 at 18:22 -0500, Benjamin Marzinski wrote:
> > So AFAICS,
On Wed, May 12, 2021 at 12:36:42PM +, Martin Wilck wrote:
> On Tue, 2021-05-11 at 18:22 -0500, Benjamin Marzinski wrote:
> > configure() can retry multiple times, each time reallocing a maps and
> > paths vector, and leaking the previous ones. Fix this by always
> > fr
On Wed, May 12, 2021 at 11:38:08AM +, Martin Wilck wrote:
> On Tue, 2021-05-11 at 18:22 -0500, Benjamin Marzinski wrote:
> > When ev_remove_path() returns success, callers assume that the path
> > (and
> > possibly the map) has been removed. When ev_remove_path() returns
On Wed, May 12, 2021 at 09:11:01AM +, Martin Wilck wrote:
> On Tue, 2021-05-11 at 18:22 -0500, Benjamin Marzinski wrote:
> > In ev_remove_path(), if update_mpp_paths() fails, we delete the
> > entire
> > map. However, since update_mpp_paths() happens before we call
>
to dereference the path after it was removed. Change
ev_remove_path() to return success whenever the path is removed, even if
the map was removed due to a failure when trying to reload it. Found by
coverity.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 6 --
1 file changed, 4 insertions
configure() can retry multiple times, each time reallocing a maps and
paths vector, and leaking the previous ones. Fix this by always freeing
the vectors before configure() exits. Found by coverity.
Signed-off-by: Benjamin Marzinski
---
multipath/main.c | 7 ++-
1 file changed, 6 insertions
If a new block was allocated, but couldn't be filled, getblock will
discard it. When it does so, it needs to free the block to avoid leaking
memory. Found by coverity.
Signed-off-by: Benjamin Marzinski
---
kpartx/kpartx.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/kpartx/kpartx.c b
remove_map_and_stop_waiter() already calls orphan_paths() so flush_map()
doesn't need to call orphan_paths() before calling
remove_map_and_stop_waiter().
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/multipathd/main.c b/multipathd
This is collection of issues found by coverity. The first three patches
deal with ev_remove_path() removing the path, but returning failure,
causing a use-after-free error. The last two patches fix memory leaks.
Benjamin Marzinski (5):
multipathd: don't fail to remove path once the map
map removed, there's nothing to keep us from removing
the path.
Call set_path_removed() before update_mpp_paths() to avoid the odd case
of ev_remove_path() removing the map but not the path.
Signed-off-by: Benjamin Marzinski
---
libmultipath/structs_vec.c | 3 +--
multipathd/main.c |
On Thu, Apr 22, 2021 at 09:07:15AM +, Martin Wilck wrote:
> On Wed, 2021-04-21 at 22:46 -0400, Martin K. Petersen wrote:
> >
> > Martin,
> >
> > > Hm, it sounds intriguing, but it has issues in its own right. For
> > > years to come, user space will have to probe whether these attribute
> >
/checkers.c
> @@ -368,7 +368,7 @@ static void checker_cleanup_thread(void *arg)
> {
> struct checker_class *cls = arg;
>
> - (void)checker_class_unref(cls);
> + (void)free_checker_class(cls);
> rcu_unregister_thread();
> }
>
> --
Reviewed-by: Benjamin Marzinsk
On Tue, Mar 30, 2021 at 11:00:56AM +0200, Martin Wilck wrote:
> On Mon, 2021-03-29 at 22:23 -0500, Benjamin Marzinski wrote:
> > On Fri, Mar 26, 2021 at 10:29:40PM +0100, mwi...@suse.com wrote:
> > >
> > > Tell me if you want this in the multipath-tools r
On Tue, Mar 30, 2021 at 10:00:02AM +0200, Martin Wilck wrote:
> On Mon, 2021-03-29 at 23:25 -0500, Benjamin Marzinski wrote:
> > On Fri, Mar 26, 2021 at 10:29:41PM +0100, mwi...@suse.com wrote:
> > > From: Martin Wilck
> > >
> > > Add the kernel-doc
on ESXi)
> will cause a "add missing path" message in every checker iteration.
>
> Fixes: b7aae60 ("multipathd: improve "add missing path" handling")
> Signed-off-by: Martin Wilck
Reviewed-by: Benjamin Marzinski
> ---
> libmultipath/discovery.c | 1
On Mon, Mar 29, 2021 at 12:12:55PM +0200, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Normally "add map" will be used to add a map which doesn't exist
> yet. Thus not finding this map in the first place is not a problem
> indicator and should be logged at level 3 only.
>
Reviewed-by:
On Fri, Mar 26, 2021 at 10:29:37PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Hi Christophe, hi Ben,
For the set
Reviewed-by: Benjamin Marzinski
> I've spent most of this week trying to improve the multipath-tools
> CI workflows on github. I now have CI workflows
On Fri, Mar 26, 2021 at 10:29:41PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Add the kernel-doc generated manpages of libdmmp to git, and
> change the libdmmp Makefile to regenerate them (only) when
> necessary.
>
> This allows us to drop perl as a build-time requirement.
Git
On Fri, Mar 26, 2021 at 10:29:40PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Until now, our CI only tested builds on Ubuntu, the default github
> runner. This commit adds containerized build/test workflows, which can cover a
> much larger range of distributions and environments.
>
On Mon, Mar 29, 2021 at 07:08:14PM +, Martin Wilck wrote:
> On Mon, 2021-03-29 at 13:20 -0500, Benjamin Marzinski wrote:
> > >
> > > multipathd could figure out the system configuration from the (non)
> > > availability of certain properties, and use an ap
On Mon, Mar 29, 2021 at 08:44:46AM +, Martin Wilck wrote:
> On Fri, 2021-03-26 at 21:18 -0500, Benjamin Marzinski wrote:
> > On Fri, Mar 26, 2021 at 05:12:36PM +, Martin Wilck wrote:
> > > On Thu, 2021-03-25 at 19:52 -0500, Benjamin Marzinski wrote:
> > > >
On Fri, Mar 26, 2021 at 05:12:36PM +, Martin Wilck wrote:
> On Thu, 2021-03-25 at 19:52 -0500, Benjamin Marzinski wrote:
> > The priorities for the EUI-64 (0x02) and NAME (0x08) scsi identifiers
> > in
> > parse_vpd_pg83() don't match their priorities in 55-scsi-sg3_id.r
If the wwid changed, the device is no longer the same, so sending add
events to the devices partitions doesn't make any sense.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/multipathd/main.c b/multipathd/main.c
index bc747d0e
If a device with a scsi name identifier has an unknown prefix,
parse_vpd_pg83() needs to advance to the next identifier, instead of
simply trying the same one again in an infinite loop.
Signed-off-by: Benjamin Marzinski
---
libmultipath/discovery.c | 2 +-
1 file changed, 1 insertion(+), 1
This patchset has minor fixups that were either suggested by Martin, or
came up through the disussions about my "Handle remapped LUNs better"
patchset.
Benjamin Marzinski (4):
libmultipath: avoid infinite loop with bad vpd page 83 identifier
libmultipath: fix priorities in pars
Instead of looping through parents and checking, just call
udev_device_get_parent_with_subsystem_devtype() to get the
right one.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 14 +-
1 file changed, 5 insertions(+), 9 deletions(-)
diff --git a/multipathd/main.c b
The priorities for the EUI-64 (0x02) and NAME (0x08) scsi identifiers in
parse_vpd_pg83() don't match their priorities in 55-scsi-sg3_id.rules.
Switch them so that they match.
Signed-off-by: Benjamin Marzinski
---
libmultipath/discovery.c | 16
1 file changed, 8 insertions
valid path had been found in a map that wasn't present
> in the udev db.
>
Reviewed-by: Benjamin Marzinski
And I'm fine with you rebasing the queue branch.
> Signed-off-by: Martin Wilck
> ---
> If this is approved, unless anyone objects, I'll simply drop the patch
> that th
recent releases of podman (3.0.1),
> this check is insufficient, because /sys/dev/block exists now in
> containers, albeit empty. So we need to check for actual entries
> in the directory.
>
> Fixes: f131e31 ("multipath-tools: devt test: avoid failure when run in
> containers
code for all callers.
>
> As we remove a symbol, the major library version must be bumped.
>
Reviewed-by: Benjamin Marzinski
> Signed-off-by: Martin Wilck
> ---
> Changes v1 -> v2:
> - log errors at -v2 in update_multipath_table() (Ben)
> - return error in updat
d be wrong,
> because they are important for multipathd's operation, to verify that
> multipathd does the right thing when discovering a discrepancy between the dm
> state and the devices present in the system. Therefore, just decrease the
> verbosity with which we invoke "mul
On Wed, Mar 17, 2021 at 06:27:26PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Since 378cb66 ("multipath: use update_pathvec_from_dm()"),
> we remove paths and even pathgroups from multipathd's data structures
> in update_multipath_table() if these paths are found to be non-existent.
On Thu, Mar 11, 2021 at 08:30:51PM +, Martin Wilck wrote:
> On Wed, 2021-02-24 at 00:33 -0600, Benjamin Marzinski wrote:
> > There are cases where the wwid of a path changes due to LUN remapping
> > without triggering uevent for the changed path. Multipathd has no
> >
Signed-off-by: Benjamin Marzinski
---
tests/alias.c | 409 +-
1 file changed, 405 insertions(+), 4 deletions(-)
diff --git a/tests/alias.c b/tests/alias.c
index 344aba73..ebe1209e 100644
--- a/tests/alias.c
+++ b/tests/alias.c
@@ -62,6 +62,25
one that it not currently in use by a dm device.
Signed-off-by: Benjamin Marzinski
---
libmultipath/alias.c | 48 +---
tests/alias.c| 22 ++--
2 files changed, 56 insertions(+), 14 deletions(-)
diff --git a/libmultipath/alias.c b
not in use. I've updated the
lookup_binding() tests to test this functionality as well.
Benjamin Marzinski (2):
libmultipath: check if user_friendly_name is in use
tests: add tests for checking if alias is in use
libmultipath/alias.c | 48 -
tests/alias.c| 427
I
> worked on that code, I really didn't want to miss any of these messages.
Reviewed-by: Benjamin Marzinski
> ---
> libmultipath/structs_vec.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/libmultipath/structs_vec.c b/libmultipath/structs
On Tue, Feb 09, 2021 at 10:19:45PM +, Martin Wilck wrote:
> On Mon, 2021-02-08 at 23:19 -0600, Benjamin Marzinski wrote:
> > If
> > multipathd notices that a path's wwid has changed it will remove and
> > re-add the path, just like the existing wwid checking code for c
Signed-off-by: Benjamin Marzinski
---
libmultipath/discovery.c | 11 ---
1 file changed, 4 insertions(+), 7 deletions(-)
diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
index 9be94cd1..3a06f319 100644
--- a/libmultipath/discovery.c
+++ b/libmultipath/discovery.c
configured to be able to use the uid_fallback
methods. To make sure both the sysfs and udev database values are
updated, multipathd triggers a both a rescan of the device and a udev
add event.
Co-developed-by: Chongyun Wu
Signed-off-by: Benjamin Marzinski
---
libmultipath/config.c
at the add uevents for the new LUN that was mapped
to the old LUN id, instead of seeing add event when the old
LUN was remapped to a new LUN id. This means that the
uev_add_path() code is unnecessary, as Martin suspected. It's
been removed.
Benjamin Marzinski
checks if pp->uid_attribute is NULL, just check once
for the code block.
Signed-off-by: Benjamin Marzinski
---
libmultipath/discovery.c | 17 -
1 file changed, 8 insertions(+), 9 deletions(-)
diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
index 3a06f319..
.
Also, keep kpartx from printing that the loop device has been removed
at normal verbosity.
Fixes: da59d15c6 ("Fix loopback file with kpartx -av")
Signed-off-by: Benjamin Marzinski
---
kpartx/kpartx.c | 9 +
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/kpartx/kp
or have
> other special needs.
>
> Also, get rid of the now obsolete global variables logsink and
> udev, as these are now defined in libmultipath.
>
Reviewed-by: Benjamin Marzinski
For the set.
> Signed-off-by: Martin Wilck
> ---
> tests/README.md | 5 +
> test
On Tue, Feb 09, 2021 at 10:19:45PM +, Martin Wilck wrote:
> On Mon, 2021-02-08 at 23:19 -0600, Benjamin Marzinski wrote:
> > There are cases where the wwid of a path changes due to LUN remapping
> > without triggering uevent for the changed path. Multipathd has no
> >
734 | extern int __sigsetjmp (struct __jmp_buf_tag *__env, int __savemask)
> __THROWNL;
> |^~~
>
> The reason seems to be a mismatch between the __sigsetjmp() prototype
> in and . Until this is fixed in the toolchain,
> work around it by inclu
ll disable this option for
that device.
If recheck_wwid_time is not turned off, multipathd will also
automatically recheck the wwid whenever an existing path gets a add
event, or is manually re-added with cli_add_path().
Co-developed-by: Chongyun Wu
Signed-off-by: Benjamin Marzinski
---
libmultipat
, uev_add_path() should only continue to access the path if
ev_remove_path() didn't succeed.
Signed-off-by: Benjamin Marzinski
---
multipathd/main.c | 15 +++
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/multipathd/main.c b/multipathd/main.c
index 425492a9..19679848 100644
the existing LUN
numbers, all the old paths should have their wwids checked as soon as
possible (immediately, if the path is up), since mismatching LUN numbers
is a red flag that something has gone wrong.
Benjamin Marzinski (2):
libmultipath: fix use-after-free in uev_add_path
multipathd: add
I've actually managed to reproduce this issue with the latest code. All
it takes is two machines in the same FC zone, with one of them having a
FC driver that supports target mode and LIO.
To do it:
You can grab TGT_WWPN and INIT_WWPN from
/sys/class/fc_host/host/port_name
On the target machine
On Tue, Feb 02, 2021 at 10:41:31PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> udev_device_get_devnum() may fail, in which case it returns
> makedev(0, 0).
>
Reviewed-by: Benjamin Marzinski
> Signed-off-by: Martin Wilck
> ---
> libmultipath/discovery.c | 3
gt; Signed-off-by: Martin Wilck
This patch looks fine, but I don't think that there was any risk before.
I don't see how you could loop back to rescan with mpp == NULL, which
is what would need to happen before you could ever run this code.
At any rate
Reviewed-by: Benjamin Marzinski
> ---
> multi
break such use cases, we need to make the
> filter_property() test in pathinfo() dependent on DI_BLACKLIST. That
> would make a lot of sense, but it'd cause a semantic change.
>
> Comments welcome.
Reviewed-by: Benjamin Marzinski
For the set.
>
> Regards
> Martin
>
>
;
> Signed-off-by: Martin Wilck
Assuming that this does resolve the issue,
Reviewed-by: Benjamin Marzinski
> ---
> libmultipath/uevent.c | 7 ---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/libmultipath/uevent.c b/libmultipath/uevent.c
> ind
o be checked, membership of the
> path to be added in mpp->paths.
>
> Fixes: 2d32d6f ("libmultipath: adopt_paths(): don't bail out on single path
> failure")
> Signed-off-by: Martin Wilck
Reviewed-by: Benjamin Marzinski
> ---
>
> @lixiaokeng, I believe tha
13/expander-9:1/port-9:1:12/expander-9:2/port-9:2:4/end_device-9:2:4/target9:0:29/9:0:29:0/block/sdac
>
> In that case, we should use the last digit as transport id.
>
> Signed-off-by: Martin Wilck
Reviewed-by: Benjamin Marzinski
> ---
> libmultipath/discovery.c | 13 ++
On Mon, Feb 01, 2021 at 11:26:36PM -0600, Benjamin Marzinski wrote:
> On Mon, Feb 01, 2021 at 04:12:34PM +0100, Martin Wilck wrote:
> > On Mon, 2021-02-01 at 22:50 +0800, lixiaokeng wrote:
> > >
> > > > >
> > > > > cli_add_path
> > >
On Mon, Feb 01, 2021 at 04:12:34PM +0100, Martin Wilck wrote:
> On Mon, 2021-02-01 at 22:50 +0800, lixiaokeng wrote:
> >
> > > >
> > > > cli_add_path
> > > > ->ev_add_path
> > > > ->add_map_with_path
> > > > ->adopt_paths
> > > > ->pathinfo
> > > >
necessary symbols resolved early on.
>
> This implementation simply creates a dummy thread and cancels
> it. This way all necessary symbols for thread cancellation
> will be loaded, no matter what the C library needs to implement
> cancellation.
>
Reviewed-by: Benjamin Marzinski
> Sig
artin Wilck
Reviewed-by: Benjamin Marzinski
> ---
> libmultipath/discovery.c | 24 +++-
> 1 file changed, 19 insertions(+), 5 deletions(-)
>
> diff --git a/libmultipath/discovery.c b/libmultipath/discovery.c
> index f3ce3f8..7878454 100644
> --- a/lib
On Thu, Jan 28, 2021 at 09:45:41PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> Hi Christophe, hi Ben,
>
> here are 3 patches I'd like to get reviewed before we create a pull
> request. The first two are related to complex SAS setups, the second
> one is to avoid accessing the root
On Thu, Jan 28, 2021 at 09:45:42PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> On SAS expanders, node id's have 3 digits. sysfs paths look like this:
>
>
On Fri, Dec 18, 2020 at 11:31:25PM +, Martin Wilck wrote:
> On Fri, 2020-12-18 at 17:06 -0600, Benjamin Marzinski wrote:
> > According to man "systemd.special"
> >
> > "shutdown.target: ... Services that shall be terminated on system
> > shutdown sha
On Tue, Jan 26, 2021 at 10:04:28AM +, Martin Wilck wrote:
> On Mon, 2021-01-25 at 23:31 -0600, Benjamin Marzinski wrote:
> > commit a839e39e ("libmpathpersist: factor out initialization and
> > teardown") made mpath_presistent_reserve_{in,out} use share variables
On Tue, Jan 26, 2021 at 09:36:59AM +, Martin Wilck wrote:
> On Mon, 2021-01-25 at 23:31 -0600, Benjamin Marzinski wrote:
> > commit a839e39e ("libmpathpersist: factor out initialization and
> > teardown") made mpath_presistent_reserve_{in,out} use share variables
atch makes mpath_presistent_reserve_{in,out} go back to using
local variables for curmp and pathvec, so that multiple threads won't
be operating on these variables at the same time.
Fixes: a839e39e ("libmpathpersist: factor out initialization and teardown")
Signed-off-by: Benjamin Marzinski
---
libmpathper
On Mon, Jan 25, 2021 at 04:23:04PM +0100, mwi...@suse.com wrote:
> From: Martin Wilck
>
> All libudev functions may return NULL. Watch out for it.
>
> Fixes: d041258 ("libmultipath: snprint_devices(): use udev_enumerate"
> Signed-off-by: Martin Wilck
Rev
if they already have a valid state, this caused multipathd to log a
message whenever the path state switched to from delayed to pending and
then back.
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 7 +++
multipathd/main.c | 25 ++---
2 files
pointer, since it should always equal _pathvec.
0004-0006 are new patches to deal with io_err_stat issues from Martin's
review
Benjamin Marzinski (1):
multipathd: cleanup logging for marginal paths
libmultipath/io_err_stat.c | 7 +++
multipathd/main.c | 25
On Fri, Jan 15, 2021 at 01:55:09PM +, Martin Wilck wrote:
> On Thu, 2021-01-14 at 20:20 -0600, Benjamin Marzinski wrote:
> > io_err_stat logged at level 2 whenever it enqueued a path to check,
> > which could happen multiple times while a path was marginal. On the
it
was set.
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 111 ++---
1 file changed, 43 insertions(+), 68 deletions(-)
diff --git a/libmultipath/io_err_stat.c b/libmultipath/io_err_stat.c
index 2e48ee81..feb66469 100644
--- a/libmultipath
Instead of calling clock_gettime(), and dealing with failure
conditions, just call get_monotonic_time().
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 34 +++---
1 file changed, 11 insertions(+), 23 deletions(-)
diff --git a/libmultipath
unexpected happens, but multipathd will always log when a
path switches its marginal state.
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 7 +++
multipathd/main.c | 25 ++---
2 files changed, 17 insertions(+), 15 deletions(-)
diff --git
being
deleted from io_err_pathvec, without the index being decremented,
causing the loop to skip elements. Also, service_paths() could be
cancelled while holding the io_err_pathvec_lock, so it should have a
cleanup handler.
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.
destroy_directio_ctx() is only called from free_io_err_stat_path(), and
free_io_err_stat_path() is very short, so combine them.
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 24 ++--
1 file changed, 10 insertions(+), 14 deletions(-)
diff --git
Signed-off-by: Benjamin Marzinski
---
libmultipath/io_err_stat.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libmultipath/io_err_stat.c b/libmultipath/io_err_stat.c
index 5363049d..2e48ee81 100644
--- a/libmultipath/io_err_stat.c
+++ b/libmultipath/io_err_stat.c
@@ -88,7
pthread_testcancel and use cleanup_mutex instead of
cleanup_unlock as suggested by Martin. Also, make tmp_pathvec a constant
pointer, since it should always equal _pathvec.
0004-0006 are new patches to deal with io_err_stat issues from Martin's
review
Benjamin Marzinski (6):
libmultipath: make
601 - 700 of 2020 matches
Mail list logo