[PATCH v2 0/3] Handle remapped LUNs better

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This patchset adds a new config option, recheck_wwid, to help deal with
devices getting remapped. It's based on Chongyun's patch. Unlike
Chongyun's patch, it doesn't issue a remove uevent. I'm not actually
sure what the purpose of the remove uevent was, since it doesn't cause
the path to be removed, and multipath already removed it.  Instead, it
works like Martin's uev_update_path code, and re-adds the path after it
removes it.  There is one issue I noticed here.  While udev will update
the WWID in the database when it gets a new uevent, sysfs will still
record the original WWID. To deal with this, the code also triggers a
rescan of the device.

Changes from v1:
  0001: New patch to cleanup trailing whitespace stripping, as suggested
	by Martin
  0002: New patch to simplify the uid_attribute checking code
  0003: Numerous changes based on Martin's review.
	- The option is now simply on or off instead of having a time
	  limit, since the overhead of checking the vpd page isn't too
	  high.
	- The option can now be set in the devices section as well.
	- handle_path_wwid_change() consistently uses a constant for
	  the strings.
	- handle_path_wwid_change() grabs a reference to the udev device
	  and then removes the path first, before triggering the uevent.
	- handle_path_wwid_change() and uev_update_path() now trigger a
	  rescan of the path device, when the wwid has changed, to
	  update the sysfs info.
	- the code now determines if it is safe to recheck the wwid the
	  same way it does for the uid fallback code.
	- When I was retesting I couldn't trigger add uevents on paths
	  being remapped.  I suspect I never could, and was accidentally
	  looking 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 (3):
  libmultipath: cleanup code to strip wwid trailing spaces
  libmultipath: cleanup uid_attribute checking code
  multipathd: add recheck_wwid option to verify the path wwid

 libmultipath/config.c             |  2 +
 libmultipath/config.h             |  2 +
 libmultipath/configure.c          |  4 +-
 libmultipath/configure.h          |  2 +
 libmultipath/defaults.h           |  1 +
 libmultipath/dict.c               | 11 +++++
 libmultipath/discovery.c          | 35 +++++++-------
 libmultipath/discovery.h          |  1 +
 libmultipath/libmultipath.version |  6 +++
 libmultipath/propsel.c            | 21 +++++++++
 libmultipath/propsel.h            |  1 +
 libmultipath/structs.h            |  7 +++
 multipath/multipath.conf.5        | 14 ++++++
 multipathd/cli_handlers.c         |  9 ++++
 multipathd/main.c                 | 78 +++++++++++++++++++++++++++++++
 multipathd/main.h                 |  2 +
 16 files changed, 176 insertions(+), 20 deletions(-)

-- 
2.17.2

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/dm-devel




[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux