Repository navigation
B #8190: Store auto-EFI NVRAM in VM system dir and check Domain not found in kvm/cancel - #8192
Open
trukhinyuri wants to merge 1 commit into
Open
trukhinyuri wants to merge 1 commit into
trukhinyuri wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The NVRAM deletion lacks the privileges required to remove libvirt-owned files.
1 open finding
What changed in this PR
Improves KVM cancellation reliability and adds UEFI NVRAM cleanup.
Changes:
- Retries transient
virsh dominfofailures. - Detects genuinely missing domains.
- Removes stale per-domain NVRAM files.
| File | Description |
|---|---|
src/vmm_mad/remotes/kvm/cancel |
Refines domain detection and adds NVRAM cleanup. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
…main not found in kvm/cancel - In LibVirtDriverKVM.cc, emit <nvram> pointing to <system_dir>/<vm_name>_VARS.fd for auto-selected EFI firmware (FIRMWARE=UEFI) just like explicit UEFI firmware paths, and skip manual OVMF_NVRAM copying in vmm_mad/remotes/kvm/deploy when /domain/os/@firmware is 'efi' so libvirt autoselection populates the NVRAM file inside the VM system directory where tm/delete cleans it up as oneadmin. - In vmm_mad/remotes/kvm/cancel, check that virsh dominfo output matches 'Domain not found' before treating a non-zero exit code as success. Signed-off-by: Iurii Trukhin <yuri@trukhin.com>
trukhinyuri
force-pushed
the
fix/kvm-cancel-nvram
branch
from
October 14, 2026 17:41
04bb4c3 to
1e9a047
Compare
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.

Description
Fixes #8190.
LibVirtDriver::deployment_description_kvm(src/vmm/LibVirtDriverKVM.cc), emit<nvram>pointing to<system_dir>/<vm_name>_VARS.fdforis_efi_auto(FIRMWARE="UEFI") just likeis_uefi, and skip the manualOVMF_NVRAMcopy insrc/vmm_mad/remotes/kvm/deploywhen/domain/os/@firmwareisefi. This lets libvirt firmware autoselection populate the NVRAM file inside the VM system directory sotm/deletecleans it up asoneadmininstead of leaving files in/var/lib/libvirt/qemu/nvram/.src/vmm_mad/remotes/kvm/cancel, checkDOMINFO_OUTforDomain not foundinstead of returning0on anyvirsh dominfoerror so transientlibvirtdfailures are retried rather than treated as successful domain removal.Branches to which this PR applies