Skip to content
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

VMNode deadloops when QEMU fails to start #30

Open
moralismercatus opened this issue Jun 15, 2017 · 0 comments
Open

VMNode deadloops when QEMU fails to start #30

moralismercatus opened this issue Jun 15, 2017 · 0 comments
Labels

Comments

@moralismercatus
Copy link
Collaborator

moralismercatus commented Jun 15, 2017

Problem Statement
When QEMU fails to start, an exception is thrown (

BOOST_THROW_EXCEPTION(VMException{} << err::process_exited{"pid_"});
). At this point, VMNode's recovery mechanism will attempt a recovery and try again to the same effect, and on indefinitely.

It should be noted that this deadloop is not encountered when QEMU terminates after VMNodeFSM has consumed a test case, because eventually test cases will be exhausted. In this case, however, no test case is consumed yet.

We have encountered this in two scenarios.

  1. The GUI for QEMU is having technical difficulties (such as can occur with Xming+Putty).
  2. The QEMU image has somehow been corrupted.

Solution
One solution is to throw a special exception designating that it originated in starting the VM, and therefore recovery should not be attempted.

See moralismercatus@13c966a In essence, I added a new exception VMNoRecoveryException that is thrown from start_vm which transitions to the Terminate state instead of the Error state. In this way, VMNode will not attempt to reboot the VM. It's not a complete solution because, while the deadloop no longer occurs, for some reason, CRETE does not terminate. Another issue here is that errors don't get propagated back to Dispatch with the Terminate state. A more thorough fix is needed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant