[Libguestfs] [PATCH] v2v: rhv-upload-plugin: Defer imageio connection

Nir Soffer nsoffer at redhat.com
Wed Jan 20 11:51:39 UTC 2021


On Wed, Jan 20, 2021 at 12:30 PM Richard W.M. Jones <rjones at redhat.com> wrote:
>
> On Wed, Jan 20, 2021 at 01:44:47AM +0200, Nir Soffer wrote:
> > I cannot test this change, since building virt-v2v on Fedora 32 fails.
> >
> > I tried:
> >
> > git clean -dxf
> > ./autogen.sh
> > make
> >
> > Make fails with:
> >
> > ...
> >   OCAMLCMI cmdline.cmi
> >   OCAMLOPT cmdline.cmx
> >   OCAMLCMI v2v.cmi
> >   OCAMLOPT v2v.cmx
> > File "v2v.ml", line 94, characters 20-48:
> > 94 |   g#set_smp (min 8 (Sysconf.nr_processors_online ()));
> >                          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> > Error: Unbound module Sysconf
> > Hint: Did you mean Scanf?
>
> I think this means the common/ submodule isn't updated, so you have
> to do:
>
> git submodule update

Right, this was missing. Build was successful with:

git clean -dxf
git submodule update --init
CFLAGS=-fPIC ./autogen.sh
make

Can we document this in the README? It may help to get more
contribution to this project.

Trying to test using this script:

$ cat rhv-upload-test.sh
#!/bin/sh

virt-v2v \
-i disk /var/tmp/fedora-32.raw \
-o rhv-upload \
-oc https://engine-dev:8443/ovirt-engine/api \
-op password \
-on v2v \
-os storage-nfs-00 \
-of raw \
-oa sparse \
-oo rhv-cafile=ca.pem \
-oo rhv-cluster=ost-el8 \
-oo rhv-direct=false

The next issue is nbdkit:

$ ./run ./rhv-upload-test.sh
nbdkit: error: cannot open plugin 'python': libpython3.7m.so.1.0:
cannot open shared object file: No such file or directory

$ ldd /usr/local/lib/nbdkit/plugins/nbdkit-python-plugin.so
linux-vdso.so.1 (0x00007ffd50d53000)
libpython3.7m.so.1.0 => not found
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f9f43636000)
libc.so.6 => /lib64/libc.so.6 (0x00007f9f4346c000)
/lib64/ld-linux-x86-64.so.2 (0x00007f9f4368f000)

Fedora 32 is using python 3.8. Looks like nbdkit package is broken.

I'll try to build and install nbdkit from source.

For simulating delay in block status, I think we can use something like:

    overlay.qcow2 -> nbdkit python

And implement a fake extents handler sleeping 70 seconds and returning
single data extent. This should be long enough to trigger this issue.




More information about the Libguestfs mailing list