-
Notifications
You must be signed in to change notification settings - Fork 985
lxd: Get config for instance on offline cluster member #14539
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
Merged
tomponline
merged 8 commits into
canonical:main
from
hamistao:show_instance_offine_member
Dec 9, 2024
Merged
lxd: Get config for instance on offline cluster member #14539
tomponline
merged 8 commits into
canonical:main
from
hamistao:show_instance_offine_member
Dec 9, 2024
Conversation
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
411a0d7 to
8df3530
Compare
Member
|
typo in pr title |
8df3530 to
de1a655
Compare
ffa1c0e to
6f8039e
Compare
Signed-off-by: hamistao <[email protected]>
610a82b to
66c3dbe
Compare
Signed-off-by: hamistao <[email protected]>
If our lxc object refers to a remote container, we can't determine its state. Useful when rendering containers on offline/unreachable cluster members. Signed-off-by: hamistao <[email protected]>
If our qemu object refers to a remote VM, we can't determine its state. Useful when rendering VMs on offline/unreachable cluster members. Signed-off-by: hamistao <[email protected]>
If not using recursion, all the instance information, besides its state, used in the response comes from the database. So when the instance's node is unavailable, return instance data with status `Error` we were unable to get its state. For a recursive request, the additional info on instance state is ungettable from a node that is not running the instance, so fail same as before. Signed-off-by: hamistao <[email protected]>
The Node field now has to be accurately set to determine the instance state. So this sets it when getting local instances. Signed-off-by: hamistao <[email protected]>
The Node field now has to be accurately set to determine the instance state. So this sets it when getting local instances from backup. Signed-off-by: hamistao <[email protected]>
66c3dbe to
a321ba7
Compare
a321ba7 to
c6be07e
Compare
Signed-off-by: hamistao <[email protected]>
c6be07e to
31b790c
Compare
tomponline
approved these changes
Dec 9, 2024
Member
tomponline
left a comment
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.
Thanks
This was referenced Dec 19, 2024
tomponline
added a commit
that referenced
this pull request
Dec 19, 2024
PR #14539 broke live migration in commit d734721 This is because when live migrating a VM, the VM's `Start()` function is called on the target side (so that live migration can occur) before the Location of the instance is updated in the DB. This in turn calls `statusCode` during the start process. The change to the `statusCode` function meant that this returned an error status because the instance was in theory non-local, and that prevented the qemu process from being started. This PR reverts the `statusCode` error change and moves that logic into the Render function. Fixes #14679
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.
If not using recursion on
GET /1.0/instances/:instanceName, almost all the instance information used in the response comes from the database. So when forwarding the request is not possible, fallback to reading the instance info from the node being queried. The only change is the response is the instance state, that in this case would show as Error since we can't determine the state of a remote instance.closes #13698