summaryrefslogtreecommitdiffstats
path: root/kickstart.py
diff options
context:
space:
mode:
authorMike Fulbright <msf@redhat.com>2000-05-24 22:22:55 +0000
committerMike Fulbright <msf@redhat.com>2000-05-24 22:22:55 +0000
commit41c39bf80a2faa6500b5f9a71db930131eb4db1e (patch)
tree4be2bfb46e8bc986387f85fe7e8225e00e0eeaaf /kickstart.py
parent7f11041ee9ca90fa8a333ce3c0a24ede4aba14be (diff)
downloadanaconda-41c39bf80a2faa6500b5f9a71db930131eb4db1e.tar.gz
anaconda-41c39bf80a2faa6500b5f9a71db930131eb4db1e.tar.xz
anaconda-41c39bf80a2faa6500b5f9a71db930131eb4db1e.zip
fixes harddrive install to not nuke source partition, and also get --onpart to work (and warn when is can't because clearpart is on
Diffstat (limited to 'kickstart.py')
-rw-r--r--kickstart.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/kickstart.py b/kickstart.py
index 27a166019..766c9c30a 100644
--- a/kickstart.py
+++ b/kickstart.py
@@ -393,6 +393,15 @@ class KickstartBase(BaseInstallClass):
self.setGroups(groups)
self.setPackages(packages)
+ # test to see if they specified to clear partitions and also
+ # tried to --onpart on a logical partition
+ if iutil.getArch() == 'i386' and self.fstab:
+ clear = self.getClearParts()
+ if clear == FSEDIT_CLEAR_LINUX or clear == FSEDIT_CLEAR_ALL:
+ for (mntpoint, (dev, fstype, reformat)) in self.fstab:
+ if int(dev[-1:]) > 4:
+ raise RuntimeError, "Clearpart and --onpart on non-primary partition %s not allowed" % dev
+
if where =="pre" or where == "post":
s = Script(script, scriptInterp, scriptChroot)
if where == "pre":