New patch submitted by Eduardo Warszawski (ewarszaw@redhat.com)
You can review this change at: http://gerrit.usersys.redhat.com/930
commit e945109a87795cef5c32150b574228c31fc6aea7 Author: Eduardo Warszawski ewarszaw@redhat.com Date: Tue Sep 13 10:39:31 2011 +0300
BZ#736301 - Don't fail lvm.getVGbyUUID() if unredable VGs found.
Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425
diff --git a/vdsm/storage/lvm.py b/vdsm/storage/lvm.py index 9bf8533..257616d 100644 --- a/vdsm/storage/lvm.py +++ b/vdsm/storage/lvm.py @@ -820,12 +820,18 @@ def getVG(vgName): def getAllVGs(): return _lvminfo.getAllVgs() #returns list
- +# TODO: lvm VG UUID should not be exposed. +# Remove this function when hsm.public_createVG is removed. def getVGbyUUID(vgUUID): # cycle through all the VGs until the one with the given UUID found for vg in getAllVGs(): - if vg.uuid == vgUUID: - return vg + try: + if vg.uuid == vgUUID: + return vg + except AttributeError, e: + # An unreloadable VG found but may be we are not looking for it. + log.debug("%s" % e.message, exc_info=True) + continue # If not cry loudly raise se.VolumeGroupDoesNotExist("vg_uuid: %s" % vgUUID)
Igor Lvovsky has posted comments on this change.
Change subject: BZ#736301 - Don't fail lvm.getVGbyUUID() if unredable VGs found. ......................................................................
Patch Set 1: Looks good to me, but someone else must approve
-- To view, visit http://gerrit.usersys.redhat.com/930 To unsubscribe, visit http://gerrit.usersys.redhat.com/settings
Gerrit-MessageType: comment Gerrit-Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Dan Kenigsberg danken@redhat.com Gerrit-Reviewer: Igor Lvovsky ilvovsky@redhat.com
Dan Kenigsberg has posted comments on this change.
Change subject: BZ#736301 - Don't fail lvm.getVGbyUUID() if unredable VGs found. ......................................................................
Patch Set 1: Verified; Looks good to me, approved
(1 inline comment)
.................................................... Commit Message Line 3: AuthorDate: 2011-09-13 10:39:31 +0300 Line 4: Commit: Eduardo Warszawski ewarszaw@redhat.com Line 5: CommitDate: 2011-09-13 10:39:31 +0300 Line 6: Line 7: BZ#736301 - Don't fail lvm.getVGbyUUID() if unredable VGs found. unredable --> unreadable Line 8: Line 9: Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 Line 10 Line 11
-- To view, visit http://gerrit.usersys.redhat.com/930 To unsubscribe, visit http://gerrit.usersys.redhat.com/settings
Gerrit-MessageType: comment Gerrit-Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 Gerrit-PatchSet: 1 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Dan Kenigsberg danken@redhat.com Gerrit-Reviewer: Igor Lvovsky ilvovsky@redhat.com
Dan Kenigsberg has posted comments on this change.
Change subject: BZ#736301 - Don't fail lvm.getVGbyUUID() if unreadable VGs found. ......................................................................
Patch Set 2: Verified; Looks good to me, approved
-- To view, visit http://gerrit.usersys.redhat.com/930 To unsubscribe, visit http://gerrit.usersys.redhat.com/settings
Gerrit-MessageType: comment Gerrit-Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Dan Kenigsberg danken@redhat.com Gerrit-Reviewer: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Igor Lvovsky ilvovsky@redhat.com
Dan Kenigsberg has submitted this change and it was merged.
Change subject: BZ#736301 - Don't fail lvm.getVGbyUUID() if unreadable VGs found. ......................................................................
BZ#736301 - Don't fail lvm.getVGbyUUID() if unreadable VGs found.
Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 --- M vdsm/storage/lvm.py 1 file changed, 9 insertions(+), 3 deletions(-)
Approvals: Dan Kenigsberg: Verified; Looks good to me, approved
-- To view, visit http://gerrit.usersys.redhat.com/930 To unsubscribe, visit http://gerrit.usersys.redhat.com/settings
Gerrit-MessageType: merged Gerrit-Change-Id: Ief82082ebb3cfb6731dc9c7905f2844c60a7f425 Gerrit-PatchSet: 2 Gerrit-Project: vdsm Gerrit-Branch: master Gerrit-Owner: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Dan Kenigsberg danken@redhat.com Gerrit-Reviewer: Eduardo Warszawski ewarszaw@redhat.com Gerrit-Reviewer: Igor Lvovsky ilvovsky@redhat.com
vdsm-patches@lists.fedorahosted.org