Bug 239779

Summary: lvm2-monitor initscript produces invalid VG errors
Product: Red Hat Enterprise Linux 4 Reporter: Milan Broz <mbroz>
Component: lvm2Assignee: Petr Rockai <prockai>
Status: CLOSED ERRATA QA Contact: Corey Marthaler <cmarthal>
Severity: medium Docs Contact:
Priority: medium    
Version: 4.5CC: agk, casmith, djuran, dwysocha, jbrassow, pvrabec, roel.teuwen
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: RHBA-2007-0753 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-11-15 15:58:32 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
lvm2-mon-initscript-workaround.patch none

Description Milan Broz 2007-05-11 10:31:45 UTC
+++ This bug was initially created as a clone of Bug #213737 +++

lvm2-2.02.21-5.el4
lvm2-cluster-2.02.21-7.el4

INIT: Entering runlevel: 3
Entering non-interactive startup
  connect() failed on local socket: Connection refused
  No volume groups found
Starting monitoring for VG WARNING::   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "WARNING:" not found
[FAILED]
Starting monitoring for VG Falling:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "Falling" not found
[FAILED]
Starting monitoring for VG back:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "back" not found
[FAILED]
Starting monitoring for VG to:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "to" not found
[FAILED]
Starting monitoring for VG local:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "local" not found
[FAILED]
Starting monitoring for VG file-based:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "file-based" not found
[FAILED]
Starting monitoring for VG locking.:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "locking." not found
[FAILED]
Starting monitoring for VG Volume:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "Volume" not found
[FAILED]
Starting monitoring for VG Groups:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "Groups" not found
[FAILED]
Starting monitoring for VG with:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "with" not found
[FAILED]
Starting monitoring for VG the:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "the" not found
[FAILED]
Starting monitoring for VG clustered:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "clustered" not found
[FAILED]
Starting monitoring for VG attribute:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "attribute" not found
[FAILED]
Starting monitoring for VG will:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "will" not found
[FAILED]
Starting monitoring for VG be:   connect() failed on local socket: Connection
refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "be" not found
[FAILED]
Starting monitoring for VG inaccessible.:   connect() failed on local socket:
Connection refused
    WARNING: Falling back to local file-based locking.
  Volume Groups with the clustered attribute will be inaccessible.
Volume group "inaccessible." not found
[FAILED]

Comment 1 RHEL Program Management 2007-05-11 10:44:15 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 6 Roel Teuwen 2007-07-31 09:34:23 UTC
In the lvm2-monitor init script, the volume groups are enumerated wrongly
because 'vgs --noheadings -o name' print a WARNING is various cases, in my case
with clustered lvm volume group at this stage in the init sequence.

start()
{
        ret=0
        # TODO do we want to separate out already active groups only?
        VGS=`vgs --noheadings -o name`
        for vg in $VGS
        do
            action "Starting monitoring for VG $vg:" $VGCHANGE --monitor y $vg |
| ret=$?
        done

        return $ret
}

Please fix the script as soon as possible.

Comment 7 Bryn M. Reeves 2007-07-31 09:57:39 UTC
already fixed in CVS:

start()
{
        ret=0
        # TODO do we want to separate out already active groups only?
        VGS=`vgs --noheadings -o name 2> /dev/null`
        for vg in $VGS
        do
            action "Starting monitoring for VG $vg:" $VGCHANGE --monitor y $vg
|| ret=$?
        done

        return $ret
}


Comment 8 Petr Rockai 2007-07-31 13:40:01 UTC
Created attachment 160319 [details]
lvm2-mon-initscript-workaround.patch

If you need to fix the initscript alone (without patching the lvm programs),
you can use a simple hack using grep -v to suppress the problematic output.
Current CVS has a proper fix and the 2> /dev/null is enough to silence the
initscript (and the fix will be part of the next RHEL update).

Comment 10 errata-xmlrpc 2007-11-15 15:58:32 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2007-0753.html