RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 1209855 - Move blkdeactivate script and blk-availability.service from lvm2 to device-mapper package
Summary: Move blkdeactivate script and blk-availability.service from lvm2 to device-ma...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: lvm2
Version: 7.2
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Peter Rajnoha
QA Contact: cluster-qe@redhat.com
URL:
Whiteboard:
Depends On:
Blocks: 1201030 1384418
TreeView+ depends on / blocked
 
Reported: 2015-04-08 10:57 UTC by Peter Rajnoha
Modified: 2023-03-08 07:27 UTC (History)
9 users (show)

Fixed In Version: lvm2-2.02.125-1.el7
Doc Type: Bug Fix
Doc Text:
The blkdeactivate script together with the blk-availability.service systemd unit has been moved from lvm2 to device-mapper package. This way, other packages which provide utilities to handle various DM device subsystems (like device-mapper-multipath) can depend on device-mapper package now, not requiring lvm2 package to be installed at the same time just to make use of the blkdeactivate script.
Clone Of:
: 1384418 (view as bug list)
Environment:
Last Closed: 2015-11-19 12:46:24 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2015:2147 0 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2015-11-19 11:11:07 UTC

Description Peter Rajnoha 2015-04-08 10:57:40 UTC
The blkdeactivate should be moved to device-mapper package from lvm2 package as blkdeactivate handles also deactivation of other device-mapper based devices, not just LVM ones (e.g. multipath and cryptsetup).

The blkdeactivate script should be patched so that it checks in runtime for presence of tools needed to do the proper deactivation and it should handle specific device-mapper subsystem only if there's higher level subsystem tool present as well to do the action properly (for example, handle LVM devices only if "lvm" binary is present and skip them otherwise).

We need this move because other device-mapper based subsystems may require blkdeactivate to handle subsystem's devices properly. See also bug #1201030 for an example where this script would help multipath to do shutdown properly - mutlipath does not need LVM for it to work properly, but it surely requires libdevmapper and it needs blkdeactivate to shut down this subsystem's devices at least.

For now, this is just a quick workaround, until we have bug #1201737 properly resolved ("Add better separation of various blkdeactivate parts handling various device types - make it pluggable").

Comment 1 Peter Rajnoha 2015-04-14 11:44:35 UTC
I've added a runtime check for lvm binary - if it's not present, no LVM handling is done with blkdeactivate script. This removes the static dependency on lvm and so we can move it to libdevmapper/device-mapper package so other DM subsystems can still make use of the general routine to deactivate DM devices.

But as stated in comment #0 above, the aim for the future is for DM subsystems (and others maybe) to provides plugins for blkdeactivate script instead of hardcoding the functionality into blkdeactivate directly - this will remove the deps altogether and such runtime checks won't be necessary anymore...

https://git.fedorahosted.org/cgit/lvm2.git/commit/?id=7a4e27eee51e89a550bc55f78daea6d943293202

!!!
Don't forget to move the blkdeactivate script from lvm2 to device-mapper package!!!
!!!

Comment 3 Corey Marthaler 2015-10-08 15:58:47 UTC
Verified that both blkdeactivate and blk-availability.service are now a part of the device-mapper pkg.



lvm2-2.02.124-1.el7:

[root@host-116 ~]# rpm -qf /usr/sbin/blkdeactivate
device-mapper-1.02.101-1.el7.x86_64
[root@host-116 ~]# rpm -qf /usr/lib/systemd/system/blk-availability.service
lvm2-2.02.124-1.el7.x86_64



lvm2-libs-2.02.130-2.el7.x86_64

[root@host-116 ~]# rpm -qf /usr/sbin/blkdeactivate
device-mapper-1.02.107-2.el7.x86_64
[root@host-116 ~]# rpm -qf /usr/lib/systemd/system/blk-availability.service
device-mapper-1.02.107-2.el7.x86_64

Comment 4 errata-xmlrpc 2015-11-19 12:46:24 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-2147.html


Note You need to log in before you can comment on or make changes to this bug.