summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2003-01-06 02:17:04 +0000
committerJeremy Katz <katzj@redhat.com>2003-01-06 02:17:04 +0000
commit418aa892e8880ac94aa134a426514e4e69cdd02a (patch)
tree6a62c36837badc637fc84dd7ad18720dfabb0351
parent4794c138aebb596e7ac98a3a77ab5b5b10db7992 (diff)
downloadanaconda-418aa892e8880ac94aa134a426514e4e69cdd02a.tar.gz
anaconda-418aa892e8880ac94aa134a426514e4e69cdd02a.tar.xz
anaconda-418aa892e8880ac94aa134a426514e4e69cdd02a.zip
if vgscan segfaults, don't traceback, just disable the use of lvm. especially
as the lvm1 tools seem to segfault often :/ not perfect but the segfault bug reports are getting old.
-rw-r--r--iw/partition_gui.py4
-rw-r--r--lvm.py6
2 files changed, 8 insertions, 2 deletions
diff --git a/iw/partition_gui.py b/iw/partition_gui.py
index 1df0cbc54..213bd8ff2 100644
--- a/iw/partition_gui.py
+++ b/iw/partition_gui.py
@@ -26,6 +26,7 @@ import copy
import types
import raid
import constants
+import lvm
from iw_gui import *
from flags import flags
@@ -1165,7 +1166,8 @@ class PartitionWindow(InstallWindow):
def makeLvmCB(self, widget):
- if not fileSystemTypeGet('physical volume (LVM)').isSupported():
+ if (not fileSystemTypeGet('physical volume (LVM)').isSupported() or
+ lvm.lvmDevicePresent == 0):
self.intf.messageWindow(_("Not supported"),
_("LVM is NOT supported on "
"this platform."), type="ok",
diff --git a/lvm.py b/lvm.py
index 6e8865a91..fb0065468 100644
--- a/lvm.py
+++ b/lvm.py
@@ -17,6 +17,7 @@ import string
import math
from flags import flags
+from rhpl.log import log
from constants import *
@@ -47,6 +48,8 @@ has_lvm()
def vgscan():
"""Runs vgscan."""
+ global lvmDevicePresent
+
if flags.test or lvmDevicePresent == 0:
return
@@ -56,7 +59,8 @@ def vgscan():
stderr = output,
searchPath = 1)
if rc:
- raise SystemError, "vgscan failed"
+ log("running vgscan failed. disabling lvm")
+ lvmDevicePresent = 0
def vgactivate(volgroup = None):
"""Activate volume groups by running vgchange -ay.