Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

fix the state cannot be restored from destroying to stopped when destroy VM failed. #1224

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

Open
txdyzdy wants to merge 1 commit into zstackio:master
base: master
Choose a base branch
Loading
from txdyzdy:yezi-1

Conversation

@txdyzdy
Copy link

@txdyzdy txdyzdy commented Dec 17, 2017

fix the state cannot be restored from destroying to stopped when destroy VM failed.

Copy link
Contributor

MaJin1996 commented Dec 18, 2017
edited
Loading

destroy vm should always succeed, so it maybe other problem, can you provide the problem details what you meet?

Copy link
Author

txdyzdy commented Dec 18, 2017
edited
Loading

The stopped event should be added in Destroying's state because it is possible that the status of the VM changed from destroying to stopped in the error function of the FlowChain.

Copy link
Author

txdyzdy commented Dec 26, 2017

Copy link
Contributor

MaJin1996 commented Dec 28, 2017
edited
Loading

Sorry to reply late. In this condition,ZStack will checkState on host, then vm state will out of Destroying unless management restart( you can destroy it again to escape destroying state after management node started).

otherwise I mean APIDestroyVm should always succeed, destroyVmOnHypervisor is possible to fail

Copy link
Contributor

So it's not root cause,you can fix that syncVm cannot sync vm state from Destroying to Destroyed. The problem is in KvmVmSyncPingTask.java, thx a lot.

Copy link
Author

txdyzdy commented Jan 3, 2018
edited
Loading

Thank you very much, I'm using an old version, after switching to the new version I found this in the method checkState in VmInstanceBase.java.

else if (VmInstanceState.Stopped.toString().equals(state) && self.getState().equals(VmInstanceState.Destroying)) {
 changeVmStateInDb(VmInstanceStateEvent.destroyed);
} ```
 

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

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /