提交 29ed72f1 编写于 作者: P Paolo Bonzini 提交者: Luiz Capitulino

migration: go to paused state after finishing incoming migration with -S

At the end of migration the machine has started already, and cannot be
destroyed without losing the guest's data.  Hence, prelaunch is the
wrong state.  Go to the paused state instead.  QEMU would reach that
state anyway (after running the guest for the blink of an eye) if the
"stop" command had been received after the start of migration.
Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
Signed-off-by: NLuiz Capitulino <lcapitulino@redhat.com>
上级 1e998146
......@@ -102,7 +102,7 @@ void process_incoming_migration(QEMUFile *f)
if (autostart) {
vm_start();
} else {
runstate_set(RUN_STATE_PRELAUNCH);
runstate_set(RUN_STATE_PAUSED);
}
}
......
......@@ -341,7 +341,7 @@ static const RunStateTransition runstate_transitions_def[] = {
{ RUN_STATE_DEBUG, RUN_STATE_RUNNING },
{ RUN_STATE_INMIGRATE, RUN_STATE_RUNNING },
{ RUN_STATE_INMIGRATE, RUN_STATE_PRELAUNCH },
{ RUN_STATE_INMIGRATE, RUN_STATE_PAUSED },
{ RUN_STATE_INTERNAL_ERROR, RUN_STATE_PAUSED },
{ RUN_STATE_INTERNAL_ERROR, RUN_STATE_FINISH_MIGRATE },
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册