[Libguestfs] [PATCH 2/9] Try hard to clean up on unclean shutdown

Richard W.M. Jones rjones at redhat.com
Fri Feb 12 12:58:00 UTC 2010


On Fri, Feb 12, 2010 at 09:39:15AM +0000, Matthew Booth wrote:
> Set autosync on the libguestfs handle, install signal handlers for SIGINT and
> SIGQUIT which explicitly close the handle, and add an END { } block which closes
> the handle in virt-v2v.pl.
> 
> Note that these measures still don't work when the user kills virt-v2v with
> Ctrl-C. We suppose this is because qemu is also receiving the SIGINT and
> shutting down before it can be shut down cleanly by libguestfs. However, the
> above changes should improve matters if this can be fixed.

ACK.

Might also be an idea to add calls to $g->sync() after key
operations, eg. invocations of 'rpm'.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora




More information about the Libguestfs mailing list