Copying the active image from dc-vault to subclouds' ansible directory during a subcloud installation

Bug #1950512 reported by Yuxing
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
StarlingX
Fix Released
Low
Yuxing

Bug Description

Brief Description
-----------------
During a remote installation of BMC configured subcloud, the active load is replicated to the subcloud's ansible directory which fills up the storage.

Severity
--------
Minor

Steps to Reproduce
------------------
1 Offer the software version which unmatches the active load's version in install values, don't offer the image path in the install values
2 Issue a subcloud installation with the subcloud add command.

Expected Behavior
------------------
We only support installation with the active load if the image path is not offered. For the other software version, abort the installation and indicate the image is required for a different version.

Actual Behavior
----------------
No error returned, the active load is replicated to the subcloud's ansible directory which fills up the storage.

Reproducibility
---------------
Reproducible

System Configuration
--------------------
DC

Branch/Pull Time/Commit
-----------------------
all

Last Pass
---------
na

Timestamp/Logs
--------------
na

Test Activity
-------------
Developer Testing

Workaround
----------
na

Yuxing (yuxing)
Changed in starlingx:
assignee: nobody → Yuxing (yuxing)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to distcloud (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/starlingx/distcloud/+/817807

Changed in starlingx:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to distcloud (master)

Reviewed: https://review.opendev.org/c/starlingx/distcloud/+/817807
Committed: https://opendev.org/starlingx/distcloud/commit/20ddd891a8532279269e93282a9dd88e43043d26
Submitter: "Zuul (22348)"
Branch: master

commit 20ddd891a8532279269e93282a9dd88e43043d26
Author: Yuxing Jiang <email address hidden>
Date: Fri Nov 12 13:56:03 2021 -0500

    Validate sw version and image in install values

    During a redfish remote installation on a BMC configured subcloud, we
    want to use the active load stored in dc-vault in to save the space in
    the root partition of the system controllers. And if the "image" value
    is not offered, we are referencing the active load in dc-vault. We
    still want to allow the users to download an image from the network
    from a specified path and software version. But it is not ensured to
    success as not covered by tests.

    This commit adds the validation if we want to reference the active
    load, to ensure we only accept the active software version in the
    install values when referencing it. After this change, if the image
    was not offered and the software version was not the active version, a
    subcloud installation will be aborted, and an error message will be
    prompted to indicate the error in install values.

    Tests:
    Happy paths:
    1. Subcloud installation with correct image path and the active
    software version.
    2. Subcloud installation with correct active software version but no
    image path.
    3. Subcloud installation with specified image path and software
    version different from the active version.
    4. Subcloud install values update with correct image path and the
    active software version.
    5. Subcloud install values update with orrect active software version
    but no image path.
    6. Subcloud install values update specified image path and software
    version different from the active version.
    7. Subcloud install values update with existing data install in DB.
    8. Subcloud install values update without existing data install in DB.

    Unhappy paths:
    1. Subcloud installation with a software version different from the
    active version but without the image path.
    2. Subcloud install values update with a software version different
    from the active version but without the image path.
    3. Subcloud install values update without the bmc address.

    Closes-bug: 1950512

    Signed-off-by: Yuxing Jiang <email address hidden>
    Change-Id: I99409616557de580054f3f88e16c4c930ebe9a24

Changed in starlingx:
status: In Progress → Fix Released
Ghada Khalil (gkhalil)
Changed in starlingx:
importance: Undecided → Low
tags: added: stx.6.0 stx.distcloud
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.