Re: [PATCH 1/2] Update extended partition geometry when we change it

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 2009-04-07 at 21:13 +0200, Hans de Goede wrote:
> 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.

Look good.

> ---
>  storage/partitioning.py |    7 +++++--
>  1 files changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/storage/partitioning.py b/storage/partitioning.py
> index 5342254..619b474 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

_______________________________________________
Anaconda-devel-list mailing list
Anaconda-devel-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/anaconda-devel-list

[Index of Archives]     [Kickstart]     [Fedora Users]     [Fedora Legacy List]     [Fedora Maintainers]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]
  Powered by Linux