On Thu, Jun 25, 2015 at 06:44:50PM +0000, Gabriel Hartmann wrote:
I have written a patch (please see attached) which fixes both of
these bugs:
https://bugzilla.redhat.com/show_bug.cgi?id=1092583
https://bugzilla.redhat.com/show_bug.cgi?id=1232477
By default, when saving a URI using xmlSaveUri it escapes everything in the
URI. QEMU doesn't want anything escaped, so now I unescape everything
after the URI is generated. Unfortunately there's no flag to change the
default behavior.
The other problem was that only the "path" portion of the URI struct was
being used to indicate the path. That's natural enough, but that practice
is what was dropping the query string. The query string is kept separately
from the path. I now concat the query string back onto the URI with a
separating '?'.
I've successfully mounted remote vhds in Azure with this new code, and the
basic set of tests pass. If there's anything else I can do by way of
verification, please let me know.
As Pino says, we can't just append the path and the query string.
I think the way to go is to add an extra parameter to the
guestfs_add_drive_opts API which would contain an OStringList of (key,
value) pairs (unescaped).
See generator/actions.ml add_drive
Rich.
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
virt-p2v converts physical machines to virtual machines. Boot with a
live CD or over the network (PXE) and turn machines into KVM guests.
http://libguestfs.org/virt-v2v