Bug 820991 - Adding an option to silently skip the clustered volume groups
Summary: Adding an option to silently skip the clustered volume groups
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: lvm2
Version: 6.3
Hardware: Unspecified
OS: Unspecified
urgent
urgent
Target Milestone: rc
: ---
Assignee: Alasdair Kergon
QA Contact: Cluster QE
URL:
Whiteboard:
: 1005415 (view as bug list)
Depends On:
Blocks: 820982 951600 986463 1024911 1034764 1116944
TreeView+ depends on / blocked
 
Reported: 2012-05-11 13:53 UTC by Federico Simoncelli
Modified: 2018-12-09 16:48 UTC (History)
23 users (show)

Fixed In Version: lvm2-2.02.100-5.el6
Doc Type: Bug Fix
Doc Text:
When there were visible clustered Volume Groups in the system, it was not possible to silently skip them with proper return error code while non-clustered locking type was used (the global/locking_type lvm.conf setting). To fix this bug, "--ignoreskippedcluster" option has been added for several LVM commands (pvs, vgs, lvs, pvdisplay, vgdisplay, lvdisplay, vgchange, and lvchange). With this option, the clustered Volume Groups are skipped correctly without any warning/error messages while the return error code also does not depend on these clustered Volume Groups.
Clone Of:
: 986463 1034764 (view as bug list)
Environment:
Last Closed: 2013-11-21 23:16:34 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2013:1704 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2013-11-20 21:52:01 UTC
Red Hat Knowledge Base (Solution) 169913 None None None Never

Description Federico Simoncelli 2012-05-11 13:53:51 UTC
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

Comment 2 RHEL Product and Program Management 2012-05-15 04:04:11 UTC
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.

Comment 4 RHEL Product and Program Management 2012-12-14 08:10:21 UTC
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.

Comment 14 Peter Rajnoha 2013-09-19 07:04:49 UTC
(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.

Comment 15 Peter Rajnoha 2013-09-19 07:05:20 UTC
*** Bug 1005415 has been marked as a duplicate of this bug. ***

Comment 16 Alasdair Kergon 2013-10-01 01:06:44 UTC
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.

Comment 21 Nenad Peric 2013-10-21 14:52:38 UTC
[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

Comment 32 John Ruemker 2013-11-08 16:32:11 UTC
Do we need another bug to pursue rc.sysinit changes?

Comment 33 Peter Rajnoha 2013-11-11 09:50:45 UTC
(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.

Comment 34 errata-xmlrpc 2013-11-21 23:16:34 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.

http://rhn.redhat.com/errata/RHBA-2013-1704.html

Comment 35 John Ruemker 2013-11-26 13:38:35 UTC
Bug for rc.sysinit change: https://bugzilla.redhat.com/show_bug.cgi?id=1034764


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