summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHans de Goede <hdegoede@redhat.com>2009-04-06 22:23:30 +0200
committerHans de Goede <hdegoede@redhat.com>2009-04-08 10:48:45 +0200
commit5a08c2bd0504f2a8c4a35251ecadcd7505e9303d (patch)
tree59c236fa4f0b25e7edd6bc4e724ee610974d0ad1
parent7862f9d132968d6610fa56fc840881762511df43 (diff)
downloadanaconda-5a08c2bd0504f2a8c4a35251ecadcd7505e9303d.tar.gz
anaconda-5a08c2bd0504f2a8c4a35251ecadcd7505e9303d.tar.xz
anaconda-5a08c2bd0504f2a8c4a35251ecadcd7505e9303d.zip
Update extended partition geometry when we change it
If there was no extended partition originally and we create one, we create the device for it, but if it changes after that (manual partitioning), we do not update the created device with the new geometry, leading to a backtrace with an overlapping partition error when the partition gets written to the disk.
-rw-r--r--storage/partitioning.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/storage/partitioning.py b/storage/partitioning.py
index 5342254eb..619b47405 100644
--- a/storage/partitioning.py
+++ b/storage/partitioning.py
@@ -570,8 +570,11 @@ def doPartitioning(storage, exclusiveDisks=None):
continue
extendedName = devicePathToName(extended.getDeviceNodeName())
- if extendedName in [p.name for p in partitions]:
- # this extended partition is preexisting
+ device = storage.devicetree.getDeviceByName(extendedName)
+ if device:
+ if not device.exists:
+ # created by us, update partedPartition
+ device.partedPartition = extended
continue
# This is a little odd because normally instantiating a partition