Because of the way Xen guest creation works, the virDomainCreateLinux
implementation for Xen is really a three stage process - first we create
the raw domain, then we have to wait for device hotplug to complete,
finally unpausing the domain.
Currently if the device hotplug fails we error out, leaving a 'braindead'
VM lying around in the paused state. This is rather confusing for users
leading to people thinking everything was OK, and thus unpausing the
guest manually, then filing bug reports when they find they've no devices
in the guest VM !
The xm tool by comparison will tear down the VM if the device hotplug fails
so the user doesn't see the paused domain after the failure. The attached
patch re-arranges the Xen driver for creating new domains to do the same
kind of thing - upon any failure we explicitly destroy the halfdead domain
Regards,
Dan.
--
|=- Red Hat, Engineering, Emerging Technologies, Boston. +1 978 392 2496 -=|
|=- Perl modules:
http://search.cpan.org/~danberr/ -=|
|=- Projects:
http://freshmeat.net/~danielpb/ -=|
|=- GnuPG: 7D3B9505 F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 -=|