On Wed, Apr 07, 2010 at 12:05:45PM +0100, Matthew Booth wrote:
If the transfer iso was mounted during conversion, virt-v2v would
always give
the following error on shutdown:
(in cleanup) umount: /tmp/transferb7icam: umount:
/sysroot/tmp/transferb7icam: not found at
/home/mbooth/src/virt-v2v/blib/lib/Sys/VirtV2V/GuestOS/RedHat.pm line 1171.
This was because the GuestOS::RedHat cleanup was being called implicitly on
exit, which is after umount_all has been called explicitly on the libguestfs
handle. This change garbage collects the guestos explicitly before the
libguestfs handle.
---
v2v/virt-v2v.pl | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/v2v/virt-v2v.pl b/v2v/virt-v2v.pl
index 08f1c8d..c7ebad3 100755
--- a/v2v/virt-v2v.pl
+++ b/v2v/virt-v2v.pl
@@ -366,6 +366,9 @@ END {
sub close_guest_handle
{
+ # Perform GuestOS cleanup before closing the handle
+ $guestos = undef;
+
Not sure what if anything is the difference between this and
undef $guestos;
but in any case it looks like a good change, ACK.
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
New in Fedora 11: Fedora Windows cross-compiler. Compile Windows
programs, test, and build Windows installers. Over 70 libraries supprt'd
http://fedoraproject.org/wiki/MinGW http://www.annexia.org/fedora_mingw