Red Hat Bugzilla – Bug 820991
Adding an option to silently skip the clustered volume groups
Last modified: 2014-07-07 12:38:37 EDT
Description of problem: When there are visible clustered vgs in the system it's not possible to silently skip them (no output and exit code 0) keeping locking_type=1. Version-Release number of selected component (if applicable): lvm2-2.02.95-7.el6.x86_64 How reproducible: 100% Steps to Reproduce: 1. create a clustered vg 2. set the locking_type=1 3. pvs Actual results: # pvs Skipping clustered volume group vg-share2 # echo $? 5 Expected results: There should be a way to skip the clustered volume groups, eg: # pvs --skip-clustered # echo $? 0
This request was not resolved in time for the current release. Red Hat invites you to ask your support representative to propose this request, if still desired, for consideration in the next release of Red Hat Enterprise Linux.
(bug #1005415) Also, during boot and the vgchange -ay call in rc.sysinit script, we get a "FAILURE" initscript status because of non-zero return value - this might be confusing (clustered VGs are activated later by another vgchange -ay call that is a part of the clvmd init script once we have cluster properly set up). The option to silently skip clustered volume groups on activation should be also used in this rc.sysinit script - once we have this option in, let's update initscripts as well.
*** Bug 1005415 has been marked as a duplicate of this bug. ***
I have a prototype patch that adds a new --ignoreskippedcluster option to pvs. This changes the 'Skipping' messages from stderr to verbose and means clustered VGs have no effect on the exit status if clustered locking is unavailable.
https://git.fedorahosted.org/cgit/lvm2.git/commit/?id=baf95bbff70bdd1474b678f37b840025295903ae
[root@virt-008 ~]# pvs --config 'global {locking_type = 1}' Skipping clustered volume group cluster Skipping volume group cluster Skipping clustered volume group cluster Skipping volume group cluster Skipping clustered volume group cluster Skipping volume group cluster Skipping clustered volume group cluster Skipping volume group cluster Skipping clustered volume group cluster Skipping volume group cluster Skipping clustered volume group cluster Skipping volume group cluster PV VG Fmt Attr PSize PFree /dev/vda2 vg_virt008 lvm2 a-- 7.51g 0 [root@virt-008 ~]# echo $? 5 [root@virt-008 ~]# pvs --ignoreskippedcluster --config 'global {locking_type = 1}' PV VG Fmt Attr PSize PFree /dev/vda2 vg_virt008 lvm2 a-- 7.51g 0 [root@virt-008 ~]# echo $? 0 [root@virt-008 ~]# Verified with: lvm2-2.02.100-6.el6.x86_64
Do we need another bug to pursue rc.sysinit changes?
(In reply to John Ruemker from comment #32) > Do we need another bug to pursue rc.sysinit changes? Yes that would be a separate change for the "initscripts" component.
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. http://rhn.redhat.com/errata/RHBA-2013-1704.html
Bug for rc.sysinit change: https://bugzilla.redhat.com/show_bug.cgi?id=1034764