opensvc / multipath-tools

Other
59 stars 47 forks source link

libmultipath: fix 'show paths format' failure #49

Closed pkoetsier closed 1 year ago

pkoetsier commented 1 year ago

Prevent 'multipathd show paths format "%c"' from failing on orphan paths. For orphan paths the checker class isn't set, which caused snprint_path_checker() to fail which in turn caused 'show paths format' to fail when the format string contained "%c".

pkoetsier commented 1 year ago

On our Kubernetes nodes, the HPE CSI driver sometimes failed to attach persistent volumes with an "unable to get scsi slaves for device..." message. It turned out this was because the CSI driver runs 'multipathd show paths format "%w %d %t %i %o %T %C %c %s %m"' to list the paths and this command was failing when there were orphan paths. This patch fixed the issue.

mwilck commented 1 year ago

Thanks, this looks ok. But although there've been a few exceptions lately, we still use a mailing-list based workflow. Please post your patch to dm-devel AT redhat.com, cc mwilck AT suse.com and bmarzins AT redhat.com.

pkoetsier commented 1 year ago

Thanks, I've posted the patch to dm-devel and am closing this PR.