diff options
author | Jeremy Katz <katzj@redhat.com> | 2004-07-07 23:12:45 +0000 |
---|---|---|
committer | Jeremy Katz <katzj@redhat.com> | 2004-07-07 23:12:45 +0000 |
commit | 14e1eb34e960310aa5943b8e731acd2c839ea425 (patch) | |
tree | c1362c50c11f0973da5868eee4a4e0f2e486fec5 /partRequests.py | |
parent | 5701f53920be5e1f0b7f243f9b96a8c3d5efe395 (diff) | |
download | anaconda-14e1eb34e960310aa5943b8e731acd2c839ea425.tar.gz anaconda-14e1eb34e960310aa5943b8e731acd2c839ea425.tar.xz anaconda-14e1eb34e960310aa5943b8e731acd2c839ea425.zip |
switch autopartitioning to use lvm by default. setup is basically
* Create /boot partition (or appropriate for the arch)
* For each drive being used in auto-partitioning, create a PV
* Use these pvs in a vg
* Create auto-partition requests as logical volumes in the vg
Diffstat (limited to 'partRequests.py')
-rw-r--r-- | partRequests.py | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/partRequests.py b/partRequests.py index 3cd4b606e..becae648d 100644 --- a/partRequests.py +++ b/partRequests.py @@ -362,7 +362,8 @@ class PartitionSpec(RequestSpec): preexist = 0, migrate = None, grow = 0, maxSizeMB = None, start = None, end = None, - drive = None, primary = None, format = None): + drive = None, primary = None, format = None, + multidrive = None): """Create a new PartitionSpec object. fstype is the fsset filesystem type. @@ -377,6 +378,8 @@ class PartitionSpec(RequestSpec): format is whether or not the partition should be formatted. preexist is whether this partition is preexisting. migrate is whether or not the partition should be migrated. + multidrive specifies if this is a request that should be replicated + across _all_ of the drives in drive """ # if it's preexisting, the original fstype should be set @@ -399,6 +402,7 @@ class PartitionSpec(RequestSpec): self.drive = drive self.primary = primary + self.multidrive = multidrive # should be able to map this from the device =\ self.currentDrive = None @@ -728,7 +732,11 @@ class VolumeGroupRequestSpec(RequestSpec): pvs = [] for pv in self.physicalVolumes: - pvs.append(partitions.getRequestByID(pv).getDevice(partitions)) + r = partitions.getRequestByID(pv) + # a size of zero implies we did autopartitioning of + # pvs everywhere we could + if (r.size > 0) or (r.device is not None): + pvs.append(r.getDevice(partitions)) self.dev = fsset.VolumeGroupDevice(self.volumeGroupName, pvs, self.pesize, existing = self.preexist) |