On Wed, 2011-02-02 at 13:30 -1000, David Cantrell wrote: > As another way to ensure the singlePV asVol requests get full pick of > what PV they want to destroy, make sure they come before the regular > asVol requests. > > (Code from Dave Lehman <dlehman@xxxxxxxxxx>) Brilliant. Ack. > > Related: rhbz#618376 > --- > storage/devicetree.py | 7 +++++++ > 1 files changed, 7 insertions(+), 0 deletions(-) > > diff --git a/storage/devicetree.py b/storage/devicetree.py > index f74d9d2..5c213ff 100644 > --- a/storage/devicetree.py > +++ b/storage/devicetree.py > @@ -610,6 +610,13 @@ class DeviceTree(object): > a2.device.partedPartition.number) > else: > ret = cmp(a1.device.name, a2.device.name) > + elif isinstance(a1.device, LVMLogicalVolumeDevice) and \ > + isinstance(a2.device, LVMLogicalVolumeDevice) and \ > + a1.device.vg == a2.device.vg: > + if a1.device.singlePV and not a2.device.singlePV: > + ret = -1 > + elif not a1.device.singlePV and a2.device.singlePV: > + ret = 1 > elif isinstance(a1.device, PartitionDevice) and \ > a2.device.partitioned: > ret = 1 _______________________________________________ Anaconda-devel-list mailing list Anaconda-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/anaconda-devel-list