On Mon, Apr 01, 2019 at 08:45:48AM -0500, Jonathan Wright wrote:
Unfortunately I do need to use the address explicitly as opposed to
hostnames because the source of the data fed here is Ceph's monmap
which returns the addresses explicitly.
I've tried all the common ways to escape the : in the v6 address to
no avail. I definitely agree that the problem looks to be it
parsing the colons as if the port comes next and then everything
after that is args.
Should I file a bug report? There doesn't seem to be any way to
prevent the : from getting parsed incorrectly.
Is it a bug in qemu? Anyway yes if it's a bug please file
a bug report about it.
Rich.
On 3/30/19 2:50 AM, Richard W.M. Jones wrote:
>On Fri, Mar 29, 2019 at 06:17:17PM -0500, Jonathan Wright wrote:
>>I have scoured the web and can't find anything on the topic: Is IPv6
>>supported for remote image targets?
>It definitely should work, although I don't know if anyone has tried
>using the address explicitly (rather than a hostname which resolves to
>an AAAA record).
>
>>For example:
>>
>>guestfish --format=raw --ro -a
>>rbd://[fd00::cefc:1]:6789/images/CentOS-7-x86_64-GenericCloud-1901
>>
>>Does not work citing the following:
>The important lines are these. Firstly guestfish parses the URL into
>an actual libguestfs API call, which looks fine to me:
>
>>libguestfs: trace: add_drive
>>"images/CentOS-7-x86_64-GenericCloud-1901" "readonly:true"
>>"format:raw" "protocol:rbd"
"server:tcp:[fd00::cefc:1]:6789"
>This is probably where it goes wrong:
>
>>"/tmp/libguestfs3pGMi6/overlay1.qcow2" "qcow2" -1
"backingfile:rbd:images/CentOS-7-x86_64-GenericCloud-1901:mon_host=[fd00::cefc:1]\:6789:auth_supported=none"
>>"backingformat:raw"
>>libguestfs: command: run: \ -o
backing_file=rbd:images/CentOS-7-x86_64-GenericCloud-1901:mon_host=[fd00::cefc:1]\:6789:auth_supported=none,backing_fmt=raw
>>libguestfs: command: run: \ /tmp/libguestfs3pGMi6/overlay1.qcow2
>>qemu-img: /tmp/libguestfs3pGMi6/overlay1.qcow2: invalid conf option
>>:cefc:1]:6789:auth_supported: No such file or directory
>>Could not open backing image to determine size.
>The code in libguestfs is supposed to turn the guestfs_add_drive
>‘servers’ parameter into a Ceph URL for qemu:
>
>
https://github.com/libguestfs/libguestfs/blob/f79129b8dc92470e3a5597daf53...
>
>and I suppose this is being done wrong somehow (I don't have a Ceph
>server to test).
>
>At a guess I would say that it seems as if ':' characters must be
>quoted somehow (backslash?) because they are also used to separate the
>address and port number.
>
>Rich.
>
--
Jonathan Wright
KnownHost, LLC
https://www.knownhost.com
--
Richard Jones, Virtualization Group, Red Hat
http://people.redhat.com/~rjones
Read my programming and virtualization blog:
http://rwmj.wordpress.com
libguestfs lets you edit virtual machines. Supports shell scripting,
bindings from many languages.
http://libguestfs.org