<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Sep 19, 2018 at 7:41 AM, Gerd Hoffmann <span dir="ltr"><<a href="mailto:kraxel@redhat.com" target="_blank">kraxel@redhat.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">  Hi,<br>
<span class=""><br>
> > Hmm, so it isn't only usb emulation, but also scsi emulation duplicated<br>
> > in spice-client.  Why this route?  Wouldn't it be simpler to run nbd<br>
> > over spice-chardev, then hook up the iso as blockdev in qemu?  Which<br>
> > you then can attach to any cdrom emulation (ide/sata/scsi/usb) in qemu?<br>
> > <br>
> > cheers,<br>
> >   Gerd<br>
> > <br>
> <br>
> No, we need to redirect a client CD, not a server one.<br>
<br>
</span>Sure, the spice client would be the nbd server and provide iso access to<br>
qemu & guest that way.<br>
<span class=""><br>
> PoC with nbd was presented and discarded in favor of client only<br>
> solution.<br>
<br>
</span>Can you summarize the reasons to discard the approach?<br></blockquote><div><br></div><div>

<div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">I will try.</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">The POC of nbd-based cd sharing was on the table. It needed some</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">unclear rework to avoid breaking ABI with mainstream spice-server.</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">The solution requires updates in qemu and spice on server side and</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">spice and spice-gtk on client side.</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Then it is functional with command-line qemu.</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">In order to make it available to regular user need to update at least also libvirt and virt-manager</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">(to add new nbd chanels), remote viewer (to select what to share).</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">The user experience is also changed - any user (whether it plans to share cd in this session or not)</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">have on guest machine several additional unloaded drives (to be loaded when the sharing</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">triggered on client side).</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><br></div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Current solution is client only (even spice-gtk only), works on any setup even with old server side.</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Control of the feature is the same as redirection of usb drives (existing usbredir filter on server side).</div><div style="font-size:small;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">Simple scsi engine added to spice-gtk.</div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
I'd expect it to be rather simple to implement.  There is nbdkit which<br>
should make it easy to implement the server in spice client.  The client<br>
side in qemu is already there.  And spice-char transport is there too.<br>
So you basically have to take the parts and put them together.  Maybe<br>
some glue code, to call blockdev_remove_medium() on disconnects etc.<br>
<br>
thanks,<br>
  Gerd<br>
<div class="HOEnZb"><div class="h5"><br>
______________________________<wbr>_________________<br>
Spice-devel mailing list<br>
<a href="mailto:Spice-devel@lists.freedesktop.org">Spice-devel@lists.freedesktop.<wbr>org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/spice-devel" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/spice-devel</a><br>
</div></div></blockquote></div><br></div></div>