dm-devel.redhat.com archive mirror
 help / color / mirror / Atom feed
From: Benjamin Marzinski <bmarzins@redhat.com>
To: Christophe Varoqui <christophe.varoqui@opensvc.com>
Cc: device-mapper development <dm-devel@redhat.com>,
	Martin Wilck <Martin.Wilck@suse.com>
Subject: [RFC PATCH v2 0/3] add library to check if device is a valid path
Date: Wed, 23 Sep 2020 23:59:26 -0500	[thread overview]
Message-ID: <1600923569-17412-1-git-send-email-bmarzins@redhat.com> (raw)

The main part of the this patchset is the first patch, which adds a
new library interface to check whether devices are valid paths. This
was designed for use in the Storage Instantiation Daemon (SID).

https://github.com/sid-project

Hopefully, I've removed all the controvertial bits from the last time I
proposed this library.

The second patch adds get_uid fallback code for dasd devices. The third
patch just changes the get_uid log level for devices configured with
uid_attribute "". This is because it is currently necessary to configure
multipath with

overrides {
        uid_attribute ""
}

to claim multipath devices with SID (instead of using multipath.rules),
since SID doesn't currently get the UID information itself, and it is
called by udev before this information is added to the udev database.

I'm resubmitting this as a RFC patchset. Assuming they are ACKed, I will
resend these patches again, along with a man page, and unit tests, on
top of Martin's revised version of his "multipath-tools: shutdown,
libdevmapper races, globals" patchset.

changes from v1
---------------

0001: This patch is now rebased on top of, and makes use of Martin's
patches that provide a default *_multipath_config, udev, and logsink.
Because of this, mpathvalid_init() now has a parameter used to set
logsink. There is also a new API function, mpathvalid_reload_config().

0003: This is completely new, since Martin pointed out that adding a new
config option to always use the fallback getuid code was unnecessary. It
just makes a uid_attribute of "" log at normal levels.

Benjamin Marzinski (3):
  multipath: add libmpathvalid library
  libmultipath: add uid failback for dasd devices
  libmultipath: change log level for null uid_attribute

 Makefile                            |   3 +-
 libmpathvalid/Makefile              |  38 ++++++
 libmpathvalid/libmpathvalid.version |  10 ++
 libmpathvalid/mpath_valid.c         | 199 ++++++++++++++++++++++++++++
 libmpathvalid/mpath_valid.h         |  61 +++++++++
 libmultipath/defaults.h             |   1 +
 libmultipath/discovery.c            |  40 +++++-
 7 files changed, 349 insertions(+), 3 deletions(-)
 create mode 100644 libmpathvalid/Makefile
 create mode 100644 libmpathvalid/libmpathvalid.version
 create mode 100644 libmpathvalid/mpath_valid.c
 create mode 100644 libmpathvalid/mpath_valid.h

-- 
2.17.2

             reply	other threads:[~2020-09-24  4:59 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-24  4:59 Benjamin Marzinski [this message]
2020-09-24  4:59 ` [RFC PATCH v2 1/3] multipath: add libmpathvalid library Benjamin Marzinski
2020-09-24  4:59 ` [RFC PATCH v2 2/3] libmultipath: add uid failback for dasd devices Benjamin Marzinski
2020-09-24  4:59 ` [RFC PATCH v2 3/3] libmultipath: change log level for null uid_attribute Benjamin Marzinski
2020-09-24  8:06   ` Martin Wilck
2020-09-24 16:20     ` Benjamin Marzinski
2020-09-24 19:03       ` Martin Wilck
2020-09-24  8:18 ` [RFC PATCH v2 0/3] add library to check if device is a valid path Martin Wilck
2020-09-24 16:30   ` Benjamin Marzinski
2020-09-24 19:22     ` Martin Wilck
2020-09-25  1:08       ` Benjamin Marzinski
2020-09-25 10:01         ` Martin Wilck
2020-09-25 15:34           ` Benjamin Marzinski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1600923569-17412-1-git-send-email-bmarzins@redhat.com \
    --to=bmarzins@redhat.com \
    --cc=Martin.Wilck@suse.com \
    --cc=christophe.varoqui@opensvc.com \
    --cc=dm-devel@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).