[Libvir] Flag to virDomainReboot to immediately reboot a domain?

Lon Hohberger lhh at redhat.com
Fri Sep 22 21:48:28 UTC 2006


Hi,

For fencing Xen domains, I would like the ability to guarantee an
immediate reboot of a domain without notifying the OS inside.
Basically, I would like something equivalent to pressing the reset
button on a physical machine.

There's a currently unused "flags" option to virDomainReboot which would
allow such an addition without breaking the ABI.

Doing getXMLDesc/Destroy/Create introduces a race condition in clusters:
What if outside management software notices notices the VM is missing
and decides to start it up on *another* host node before we bring up the
VM again using the Create call?

An immediate reboot should eliminate the race (even though it's a very
small window), and probably will not add any complexity.  For now,
'reboot' is done as above, and 'off' is a simple Destroy call.

'On' is not possible to implement for various reasons, the most obvious
of which is that the caller does not know any of the configuration
information about particular domUs (except for their names).

-- Lon




More information about the libvir-list mailing list