Error running virt-v2v
Hi, I am currently unable to run virt-v2v. See output below: $ export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 $ sudo virt-v2v -i ova /home/path/kx-platform-vm-20210318-123942/kx-platform-vm-20210318-123942.ova -o libvirt -of qcow2 -os Appliances -n default [sudo] password for ib-poc: [ 0.0] Opening the source -i ova /home/path/kx-platform-vm-20210318-123942/kx-platform-vm-20210318-123942.ova virt-v2v: warning: making OVA directory public readable to work around libvirt bug https://bugzilla.redhat.com/1045069 virt-v2v: warning: could not parse ovf:Name from OVF document [ 2.5] Creating an overlay to protect the source from being modified [ 2.6] Opening the overlay [ 6.5] Inspecting the overlay [ 17.3] Checking for sufficient free disk space in the guest [ 17.3] Estimating space required on target for each disk [ 17.3] Converting CentOS Linux release 7.9.2009 (Core) to run on KVM virt-v2v: This guest has virtio drivers installed. [ 64.0] Mapping filesystem data to avoid copying unused and blank areas [ 64.8] Closing the overlay [ 65.1] Assigning disks to buses [ 65.1] Checking if the guest needs BIOS or UEFI to boot [ 65.1] Initializing the target -o libvirt -os Appliances [ 65.1] Copying disk 1/1 to /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda (qcow2) virt-v2v: error: libguestfs error: qemu-img: /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda: qemu-img exited with error status 1. To see full error messages you may need to enable debugging. Do: export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 and run the command again. For further information, read: http://libguestfs.org/guestfs-faq.1.html#debugging-libguestfs You can also run 'libguestfs-test-tool' and post the *complete* output into a bug report or message to the libguestfs mailing list. If reporting bugs, run virt-v2v with debugging enabled and include the complete output: virt-v2v -v -x [...] I also ran libguestfs-test-tool as suggested. The output is attached. Any assistance on this would be greatly appreciated. Regards, Eoghan Eoghan O'Hara | Data Scientist | *Kx* | +353 858398926 | eohara@kx.com | Pronounced "oh-an"
On Fri, Mar 19, 2021 at 09:49:58AM +0000, Eoghan O'Hara wrote:
Hi,
I am currently unable to run virt-v2v. See output below:
$ export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 $ sudo virt-v2v -i ova /home/path/kx-platform-vm-20210318-123942/ kx-platform-vm-20210318-123942.ova -o libvirt -of qcow2 -os Appliances -n default
Unfortunately these environment variables don't get passed through sudo. You will have to run virt-v2v with the additional options “-v -x” in order to see what's really going on. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 100 libraries supported. http://fedoraproject.org/wiki/MinGW
Hi Richard, I included -v and -x, and have attached the output below. Thanks, Eoghan Eoghan O'Hara | Data Scientist | *Kx* | +353 858398926 | eohara@kx.com | Pronounced "oh-an" On Sat, 20 Mar 2021 at 12:13, Richard W.M. Jones <rjones@redhat.com> wrote:
On Fri, Mar 19, 2021 at 09:49:58AM +0000, Eoghan O'Hara wrote:
Hi,
I am currently unable to run virt-v2v. See output below:
$ export LIBGUESTFS_DEBUG=1 LIBGUESTFS_TRACE=1 $ sudo virt-v2v -i ova /home/path/kx-platform-vm-20210318-123942/ kx-platform-vm-20210318-123942.ova -o libvirt -of qcow2 -os Appliances -n default
Unfortunately these environment variables don't get passed through sudo.
You will have to run virt-v2v with the additional options “-v -x” in order to see what's really going on.
Rich.
-- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com Fedora Windows cross-compiler. Compile Windows programs, test, and build Windows installers. Over 100 libraries supported. http://fedoraproject.org/wiki/MinGW
On Mon, Mar 22, 2021 at 10:11:08AM +0000, Eoghan O'Hara wrote:
Hi Richard,
I included -v and -x, and have attached the output below.
The reason is when we create the output, the target device is not writable, apparently it's a read-only filesystem: [ 65.4] Copying disk 1/1 to /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda (qcow2) ... libguestfs: trace: disk_create "/datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda" "qcow2" 262144000000 "preallocation:sparse" "compat:1.1" libguestfs: command: run: qemu-img libguestfs: command: run: \ create libguestfs: command: run: \ -f qcow2 libguestfs: command: run: \ -o preallocation=off,compat=1.1 libguestfs: command: run: \ /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda libguestfs: command: run: \ 262144000000 qemu-img: /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda: Could not create file: Read-only file system You're using “-o libvirt -os Appliances” which means it's trying to use a libvirt storage pool called “Appliances”, which presumably is mapped to /datassd/3/libvirt/Appliances in your case. You can find out about libvirt storage pools here: https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/htm... Might be best to use “-o local -os /some/writable/directory” and then you will end up with a libvirt XML file and the raw disks, and you can choose what to do with them. Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-builder quickly builds VMs from scratch http://libguestfs.org/virt-builder.1.html
Hi Richard, Yes the issue is with my filesystem. Thank you for the support! Eoghan Eoghan O'Hara | Data Scientist | *Kx* | +353 858398926 | eohara@kx.com | Pronounced "oh-an" On Mon, 22 Mar 2021 at 11:53, Richard W.M. Jones <rjones@redhat.com> wrote:
On Mon, Mar 22, 2021 at 10:11:08AM +0000, Eoghan O'Hara wrote:
Hi Richard,
I included -v and -x, and have attached the output below.
The reason is when we create the output, the target device is not writable, apparently it's a read-only filesystem:
[ 65.4] Copying disk 1/1 to /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda (qcow2) ... libguestfs: trace: disk_create "/datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda" "qcow2" 262144000000 "preallocation:sparse" "compat:1.1" libguestfs: command: run: qemu-img libguestfs: command: run: \ create libguestfs: command: run: \ -f qcow2 libguestfs: command: run: \ -o preallocation=off,compat=1.1 libguestfs: command: run: \ /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda libguestfs: command: run: \ 262144000000 qemu-img: /datassd/3/libvirt/Appliances/kx-platform-vm-20210318-123942-sda: Could not create file: Read-only file system
You're using “-o libvirt -os Appliances” which means it's trying to use a libvirt storage pool called “Appliances”, which presumably is mapped to /datassd/3/libvirt/Appliances in your case. You can find out about libvirt storage pools here:
https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/htm...
Might be best to use “-o local -os /some/writable/directory” and then you will end up with a libvirt XML file and the raw disks, and you can choose what to do with them.
Rich.
-- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones Read my programming and virtualization blog: http://rwmj.wordpress.com virt-builder quickly builds VMs from scratch http://libguestfs.org/virt-builder.1.html
participants (2)
-
Eoghan O'Hara -
Richard W.M. Jones