Uploaded image for project: 'Red Hat OpenStack Services on OpenShift'
  1. Red Hat OpenStack Services on OpenShift
  2. OSPRH-22373

baremetal-info.yml sets boot_mode to legacy despite VMs having UEFI/nvram

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Normal Normal
    • None
    • None
    • ci-framework
    • None
    • 3
    • False
    • Hide

      None

      Show
      None
    • False
    • ?
    • rhos-ops-day1day2-edpm
    • None
    • EDPM Sprint 15
    • 1
    • Important

      Description

        When ci-framework generates the baremetal-info.yml file, the boot_mode field is incorrectly set to legacy for virtual machines that were created with UEFI firmware
        (and have nvram files). This causes subsequent baremetal provisioning operations to fail or behave incorrectly since the boot mode doesn't match the actual VM
        configuration.

      Root Cause

        The generate_bm_info.yml task runs on controller-0 via delegation with delegate_facts: false, which means the _cifmw_libvirt_manager_layout fact (which contains the
        UEFI configuration) is not available on the delegated host. The boot mode detection logic attempts to read the uefi field from this unavailable fact and defaults to
        false, resulting in boot_mode: "legacy".

        1. VMs are created with UEFI firmware and nvram files when vm_data.uefi is true:
        https://github.com/openstack-k8s-operators/ci-framework/blob/a63bdc6a4f1949aa2ff58b12601d38ecb0feda57/roles/libvirt_manager/templates/domain.xml.j2#L5-L14
        2. The configure_controller.yml task delegates to controller-0 without delegating facts:
        https://github.com/openstack-k8s-operators/ci-framework/blob/a63bdc6a4f1949aa2ff58b12601d38ecb0feda57/roles/reproducer/tasks/configure_controller.yml#L11-L12
        3. The generate_bm_info.yml task attempts to read _cifmw_libvirt_manager_layout.vms[_type].uefi which doesn't exist on controller-0, causing it to default to false:
        https://github.com/openstack-k8s-operators/ci-framework/blob/a63bdc6a4f1949aa2ff58b12601d38ecb0feda57/roles/reproducer/tasks/generate_bm_info.yml#L81-L86

      Impact

        - Baremetal provisioning using the generated baremetal-info.yml will use legacy boot mode settings for VMs that require UEFI
        - This can cause boot failures or require manual correction of the baremetal-info.yml file
        - Affects all reproducer deployments and architecture-based scenarios that use UEFI-enabled VMs (e.g., scenarios with cifmw_use_uefi: true)

              jslagle@redhat.com James Slagle
              jslagle@redhat.com James Slagle
              rhos-dfg-df
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated: