[Libguestfs] [PATCH NOT WORKING nbdkit] vddk: Restructure plugin to allow greater parallelism.

Richard W.M. Jones rjones at redhat.com
Thu Oct 10 10:09:22 UTC 2019


We had a query yesterday about the VDDK plugin and making it actually
obey the weird "Multithreading Considerations" rules in the VDDK
documentation
(https://vdc-download.vmware.com/vmwb-repository/dcr-public/8f96698a-0e7b-4d67-bb6c-d18a1d101540/ef536a47-27cd-481a-90ef-76b38e75353c/vsphere-vddk-671-programming-guide.pdf)

This patch is my attempt to implement this.

The idea is that the plugin starts a background thread and routes all
calls to certain VDDK functions through this thread, ensuring that the
"Multithreading Considerations" are obeyed.

It doesn't work.  Because we start the background thread when the
plugin is loaded, when nbdkit forks the thread disappears.  It's
possible that we need in nbdkit a supported way for plugins to create
background threads.

In any case the actual benefit of this patch is dubious.  Closer
reading of the documentation indicates that VDDK does not allow full
parallel requests on single handles.  The way we normally use VDDK
(eg. from virt-v2v) is that we only have a single connection open (and
therefore a single handle).  So whether we'd gain any benefit in real
world cases seems unlikely.

We cannot enable multi-conn on writable VDDK handles because the
documentation gives us no indication that VDDK provides the required
guarantees, although we might consider enabling multi-conn for
readonly handles.

Rich.





More information about the Libguestfs mailing list