Bug 1249495 - [REGRESSION] rhts_partitions needlessly creates a BIOS boot partition
Summary: [REGRESSION] rhts_partitions needlessly creates a BIOS boot partition
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Beaker
Classification: Retired
Component: lab controller
Version: 20
Hardware: Unspecified
OS: Unspecified
medium
unspecified
Target Milestone: ---
Assignee: beaker-dev-list
QA Contact: tools-bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-08-03 07:57 UTC by Jun'ichi NOMURA
Modified: 2020-11-16 18:57 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-11-16 18:56:07 UTC
Embargoed:


Attachments (Terms of Use)
Add 'want_bios_boot_partition' ks_meta (683 bytes, patch)
2015-08-03 07:57 UTC, Jun'ichi NOMURA
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1230997 0 high CLOSED use new Anaconda reqpart command in kickstart snippet for custom partitioning 2021-02-22 00:41:40 UTC

Internal Links: 1230997

Description Jun'ichi NOMURA 2015-08-03 07:57:45 UTC
Created attachment 1058666 [details]
Add 'want_bios_boot_partition' ks_meta

Description of problem:
  rhts_partitions needlessly creates a BIOS boot partition

Version-Release number of selected component (if applicable):
  beaker-server-20.1-1.el6eng

How reproducible:
  Always if the system meets following conditions
    - non-EFI
    - x86
    - RHEL7 or Fedora
    - Custom partitioning is specified (e.g. 'partitions', 'ondisk')

Steps to Reproduce:
  Provision non-EFI x86 system with custom partitioning and with RHEL7

Expected results:
  BIOS boot partition should not be created if the system doesn't boot
  from >2TB disk or user requests to do so

Actual results:
  BIOS boot partition is created even if the system doesn't have >2TB disks

Additional information:
  The change was introduced intentionally with this change:
    define biosboot partition in cases where it might be necessary
      Bug: 1108393
      Change-Id: I463ab8978eaafcb25021e168b5bf46454ce0b9dd

  It seems 'has_gpt_bios_support' ks_meta was introduced to mean the
  operating system has BIOS boot partition support.

    {% if partitions or ondisk or rootfstype or fstype or swapsize %}
    ...
    {% elif distro_tree is arch('i386', 'x86_64') %}
    {% if system and system.has_efi %}
    ...
    {% else %}
    {# x86 BIOS #}
    {% if has_gpt_bios_support is defined %}
    {# biosboot partition is needed in case Anaconda uses GPT (when the disk is >2TB) #}
    part biosboot --size 1 --fstype biosboot

  As a provisioning tool for test system, it is undesirable to create
  the partition which is not requested and which will not be created
  in customer's actual installation scenario.
  By beaker 'kindly' adding the partition, we might unable to find
  possible bugs in installer or boot loader in testing, for example.

  Given that the number of systems that require BIOS boot partition should
  be limited (newer systems have EFI, older systems boot from small disk), 
  how about making it opt-in behaviour by introducing new ks_meta such as 
  'want_bios_boot_partition'?
  (A patch is attached)

  If admins want to control the behaviour per system, they can give it
  in "Installation Options" of systems.
  If admins want to force the behaviour for all systems, they can give
  it in beaker.ks_meta of /etc/beaker/server.cfg.

Comment 1 Dan Callaghan 2015-10-12 04:38:15 UTC
Ideally we would just let Anaconda decide what partitions are needed for booting and have it create those. We will be able to do that using the new reqpart command in RHEL7.2+, that's bug 1230997.

Comment 2 Dan Callaghan 2015-10-12 04:40:39 UTC
As a workaround, if your lab has no systems with >2TB disks and BIOS-compatible firmware then you can edit the install options for RedHatEnterpriseLinux7 family and set "!has_gpt_bios_support" in ksmeta. This is essentially lying to Beaker by telling it that RHEL7 does not support GPT on BIOS-compatible firmware, but it will have the desired effect.

Comment 3 Dan Callaghan 2017-11-07 04:17:08 UTC
Jun'ichi, do you think the workaround in comment 2, plus the proper solution of "reqpart" in bug 1230997, is satisfactory? Could I close this bug?

Comment 4 Jun'ichi NOMURA 2017-11-07 05:51:54 UTC
Could I apply "!has_gpt_bios_support" workaround for all systems/distros in the lab by adding it in /etc/beaker/server.cfg?

Comment 5 Dan Callaghan 2017-11-07 06:00:14 UTC
Hmmm, unfortunately that won't work. The "has_gpt_bios_support" variable is filled in by default at the distro family level. So the workaround needs to be set either on the distro family, individual distro trees, or individual systems, so that it overrides the default.

Comment 6 Jun'ichi NOMURA 2017-11-07 08:12:42 UTC
Ok. Then I think we'll somehow workaround the issue and I'm fine if you close this bug.

Just a comment. Basically I want beaker provisions the system by default with normal and basic configuration and provides some opt-in options for particular systems/distros/users/recipes to select specific configuration. I hope "reqpart" solution works in that way.

Comment 7 Dan Callaghan 2017-11-08 03:49:11 UTC
Yes, by using the "reqpart" command, the end result should be the same as today. Except the superfluous biosboot partition will not be created, because Anaconda is smart enough to decide at installation time whether it is needed.

So using "reqpart" is really taking it closer to being a default configuration with fewer customisations.


Note You need to log in before you can comment on or make changes to this bug.