Repository navigation
Conversation
On Dell iDRAC, BootSourceOverrideTarget=Cd can resolve to a stale OS-loader boot entry that sits on the virtual CD USB path (for example ".../CDROM(0x1)/\EFI\fedora\shimx64.efi" left by an older shim-based ISO). If the current ISO does not contain that loader, the BIOS uses up the one-time boot and silently falls back to the disk. For Dell hosts in UEFI mode, _ensure_boot_once_single now translates a Cd request into BootSourceOverrideTarget=UefiTarget with UefiTargetBootSourceOverride set to the exact "Virtual Optical Drive" device path discovered from BootOptions. OS-loader entries on the same path are ignored. It falls back to Cd for legacy mode, non-Dell vendors, or when the boot option cannot be found. iDRAC applies the UEFI target through a BIOS job, so until the next POST the system resource reports a null path. Idempotency checks and boot_from_iso verification therefore accept either the active UefiTargetBootSourceOverride or the pending BIOS OneTimeUefiBootPath, and the reset is still withheld if neither matches. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The plain Cd boot override works on most Dell hosts, and UefiTarget adds an extra BIOS-job reboot. Gate the virtual optical UefiTarget translation behind a new dell_uefi_target flag (default False) on boot_from_iso and ensure_boot_once, so default behavior is unchanged and callers can enable it for hosts where a stale boot entry on the virtual CD hijacks Cd. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
On Dell iDRAC,
BootSourceOverrideTarget=Cdcan resolve to a stale OS-loader UEFI boot entry on the virtual CD's USB path, for example.../USB(0x1,0x0)/CDROM(0x1)/\EFI\fedora\shimx64.efi, left by an older shim-based ISO. If the ISO now mounted doesn't contain that loader, the BIOS uses up the one-time boot and silently falls back to the disk.boot_from_isoreports success, but the host boots its installed OS.We hit this on lab hosts where the stale entry sat first in
BootOrder. Pointing the override at the exact device path of the "Virtual Optical Drive" boot option (UefiTarget) booted the ISO reliably.Change
A new opt-in flag,
dell_uefi_target(defaultFalse), onboot_from_isoandensure_boot_once. Default behavior is unchanged: plainCd.When the flag is enabled:
Cdrequest becomesUefiTargetwithUefiTargetBootSourceOverrideset to the Virtual Optical Drive's device path, discovered fromBootOptions. OS-loader entries on the same path are ignored.Cd(logging a warning) for legacy mode, non-Dell vendors, or when no Virtual Optical Drive boot option exists. Dell only lists that option after a POST with virtual media attached.UefiTargetBootSourceOverride. Idempotency checks andboot_from_isoverification therefore accept either the active value or the pending BIOSOneTimeUefiBootPath. The reset is still withheld if neither matches.Results now include
boot_targetanduefi_target_path. README and AGENTS docs are updated.Testing
Cdand never queriesBootOptions;$expand;Cd;boot_from_isoend-to-end, including blocking the reset when the target is not in effect;black -l 120andflake8are clean.Cdhad fallen back to the disk. The read-only discovery helper returned the correct path on four Dell hosts, including one with a stale CD loader entry. It returned none on a host with no Virtual Optical Drive boot option, which triggers the fallback.🤖 Generated with Claude Code