[blivet][master/rhel7-branch] Make implicit partitions smaller if real requests don't fit anywhere

Vratislav Podzimek vpodzime at redhat.com
Mon Jan 26 09:48:56 UTC 2015


On Wed, 2015-01-21 at 10:06 +0100, Vratislav Podzimek wrote:
> In case of BTRFS/LVM autopartitioning we schedule one parition on every disk
> used for the installation to be part of the new BTRFS/LVM setup. But in case
> some other partition needs to be allocated (e.g. swap in case of BTRFS) we need
> to fit this partition to some disk together with one of the implicitly scheduled
> ones. In case we find out the implicitly scheduled partitions are too big to
> make this possible we need to make them smaller so that autopartitioning works.
> 
> Resolves: rhbz#1171116
> Signed-off-by: Vratislav Podzimek <vpodzime at redhat.com>
> ---
>  blivet/devices.py      |  7 ++++++-
>  blivet/partitioning.py | 20 +++++---------------
>  2 files changed, 11 insertions(+), 16 deletions(-)
> 
> diff --git a/blivet/devices.py b/blivet/devices.py
> index f67c5b5..576fe07 100644
> --- a/blivet/devices.py
> +++ b/blivet/devices.py
> @@ -53,6 +53,11 @@ from .i18n import P_
>  import logging
>  log = logging.getLogger("blivet")
>  
> +DEFAULT_PART_SIZE = Size("500MiB")
> +
> +# in case the default partition size doesn't fit
> +FALLBACK_DEFAULT_PART_SIZE = Size("10MiB")
dlehman has pointed out that this is too small for BTRFS which CURRENTLY
requires 16 MiB as the minimum member size and 256 MiB as the minimum
volume size. So this should be 256 MiB which still fixes the issue
reported in the bug report (tested). A proper general solution to this
issue would be more complicated and much more invasive.

-- 
Vratislav Podzimek

Anaconda Rider | Red Hat, Inc. | Brno - Czech Republic



More information about the anaconda-patches mailing list