summaryrefslogtreecommitdiffstats
path: root/fsset.py
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2001-08-10 00:13:13 +0000
committerJeremy Katz <katzj@redhat.com>2001-08-10 00:13:13 +0000
commit952286fa8707d8fe240b360c07b4e1b61735a691 (patch)
treec07e922fc96071677aab852733c0914d90ece3f3 /fsset.py
parent060cfcbcb4878b36d08a6f7a95493505f71e62c2 (diff)
downloadanaconda-952286fa8707d8fe240b360c07b4e1b61735a691.tar.gz
anaconda-952286fa8707d8fe240b360c07b4e1b61735a691.tar.xz
anaconda-952286fa8707d8fe240b360c07b4e1b61735a691.zip
if there's no journal after running tune2fs pop up a window asking if the user wants to continue
Diffstat (limited to 'fsset.py')
-rw-r--r--fsset.py21
1 files changed, 19 insertions, 2 deletions
diff --git a/fsset.py b/fsset.py
index ec718eb70..0a84b0d63 100644
--- a/fsset.py
+++ b/fsset.py
@@ -312,7 +312,7 @@ class ext2FileSystem(extFileSystem):
self.migratetofs = ['ext3']
- def migrateFileSystem(self, entry, progress, chroot='/'):
+ def migrateFileSystem(self, entry, message, chroot='/'):
devicePath = entry.device.setupDevice(chroot)
if not entry.fsystem or not entry.origfsystem:
@@ -335,6 +335,23 @@ class ext2FileSystem(extFileSystem):
if rc:
raise SystemError
+ # XXX this should never happen, but appears to have done
+ # so several times based on reports in bugzilla.
+ # At least we can avoid leaving them with a system which won't boot
+ if not isys.ext2HasJournal(devicePath, makeDevNode = 0):
+ log("Migration of %s attempted but no journal exists after "
+ "running tune2fs.\n" % (devicePath))
+ if message:
+ rc = message(_("Error"),
+ _("An error occurred migrating %s to ext3. It is "
+ "possible to continue without migrating this "
+ "filesystem if desired.\n\n"
+ "Would you like to continue without migrating %s?")
+ % (devicePath, devicePath), type = "yesno")
+ if rc == 0:
+ sys.exit(0)
+ entry.fsystem = entry.origfsystem
+
fileSystemTypeRegister(ext2FileSystem())
@@ -845,7 +862,7 @@ class FileSystemSet:
if not entry.origfsystem.isMigratable() or not entry.getMigrate():
continue
try:
- entry.origfsystem.migrateFileSystem(entry, self.progressWindow,
+ entry.origfsystem.migrateFileSystem(entry, self.messageWindow,
chroot)
except SystemError:
if self.messageWindow: