Skip to content

fix: pick the correct manager/system on multi-system, multi-chassis hosts#108

Open
shevchenko-evgeny wants to merge 1 commit into
NVIDIA:mainfrom
shevchenko-evgeny:multi_chassis_fix
Open

fix: pick the correct manager/system on multi-system, multi-chassis hosts#108
shevchenko-evgeny wants to merge 1 commit into
NVIDIA:mainfrom
shevchenko-evgeny:multi_chassis_fix

Conversation

@shevchenko-evgeny

Copy link
Copy Markdown

Match the system by presence of a Bios resource and select the manager whose Links.ManagerForServers references it, instead of blindly taking the first entry.

…osts

Match the system by presence of a Bios resource and select the manager
whose Links.ManagerForServers references it, instead of blindly taking
the first entry. Adds ManagerLinks, get_manager_with_id, is_bios_attributes.

Signed-off-by: Evgeny Shevchenko <eshevchenko@mirantis.com>
@copy-pr-bot

copy-pr-bot Bot commented Jul 21, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

Comment thread src/network.rs
// call set_system_id always before calling set_vendor
s.set_system_id(system_id)?;

// Try to find manager with ManagerForServers related to System

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might be better to look at the ManagedBy Link on the chosen System to pick the manager instead of traversing all managers for the selected System:

        "ManagedBy": [
            {
                "@odata.id": "/redfish/v1/Managers/BMC_0"
            }
        ],

Comment thread src/network.rs

//Find another system with BIOS section
let mut system_with_bios = None;
for system_member in &systems {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be better to use the bios property on the fetched System itself:

for id in &systems {
    let Ok((_, system)) = s
        .client
        .get::<ComputerSystem>(&format!("Systems/{id}"))
        .await
    else {
        break; // Use the existing fallback.
    };
    if system.bios.is_some() {
        system_id = id;
        break;
    }
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants