-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix bug of possible re-trigger of memory dump #9260
Fix bug of possible re-trigger of memory dump #9260
Conversation
@@ -1186,6 +1186,10 @@ func (l *LibvirtDomainManager) MemoryDump(vmi *v1.VirtualMachineInstance, dumpPa | |||
func (l *LibvirtDomainManager) memoryDump(vmi *v1.VirtualMachineInstance, dumpPath string) error { | |||
logger := log.Log.Object(vmi) | |||
|
|||
skip := l.shouldSkipMemoryDump(dumpPath) | |||
if skip { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't
if l.shouldSkipMemoryDump(dumpPath) {
return nil
}
Work? Not a big deal
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
done
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mhenriks The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Checking the memory dump file path and seeing it already updated indicates that the request dump already occured or in progress we dont want to simply return we want to skip this duplicate call. Signed-off-by: Shelly Kagan <skagan@redhat.com>
c52be3f
to
fd7c6a2
Compare
/retest |
@ShellyKa13: The following test failed, say
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
/retest-required |
2 similar comments
/retest-required |
/retest-required |
@ShellyKa13 should we cherrypick this? |
yep |
@ShellyKa13: new pull request created: #9295 In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Checking the memory dump file path and seeing it already updated indicates that the request dump already occured or in progress we dont want to simply return we want to skip this duplicate call.
What this PR does / why we need it:
This bug was introduced in this commit: f7c1a4c
of refactoring the virt-launcher to use metadata cache instead of libvirt metadata #8820
In it when identifying that the metadata is already updated with the dump path instead of skipping the core dump command it just returned silently.
So in case of calling the virt-launcher memory dump before the status of the memory dump updated on the VM as succeeded caused the core dump command to be called again although dump marked as completed on the VM.
Which issue(s) this PR fixes (optional, in
fixes #<issue number>(, fixes #<issue_number>, ...)
format, will close the issue(s) when PR gets merged):Fixes # This should fix flakiness in test: [sig-storage] VirtualMachineSnapshot Tests [storage-req] With online vm snapshot with memory dump [test_id:8922]should include memory dump in vm snapshot
The tests sometimes fails because a second memory dump is triggered after already marking to the test that the memory dump completed, and so the snapshot was taken and wasn't succeeded in 30 secs since the VM was paused due to the memory dump and couldn't freeze in order to perform the online snapshot.
Special notes for your reviewer:
Release note: