Revision f02881e0 lib/hypervisor/hv_kvm.py

b/lib/hypervisor/hv_kvm.py
393 393
    # For some reason if we do a 'send-key ctrl-alt-delete' to the control
394 394
    # socket the instance will stop, but now power up again. So we'll resort
395 395
    # to shutdown and restart.
396
    self.StopInstance(instance)
397
    self.StartInstance(instance)
396

  
397
    # StopInstance will delete the saved KVM runtime so:
398
    # ...first load it...
399
    kvm_runtime = self._LoadKVMRuntime(instance)
400
    # ...now we can safely call StopInstance...
401
    if not self.StopInstance(instance):
402
      self.StopInstance(instance, force=True)
403
    # ...and finally we can save it again, and execute it...
404
    self._SaveKVMRuntime(instance, kvm_runtime)
405
    self._ExecuteKVMRuntime(instance, kvm_runtime)
398 406

  
399 407
  def GetNodeInfo(self):
400 408
    """Return information about the node.

Also available in: Unified diff