libvirt/tests/qemuxml2argvdata/qemuxml2argv-disk-drive-network-rbd-ipv6.args
Josh Durgin c1509ab47e qemu: escape ipv6 for rbd network disk hosts
Hosts for rbd are ceph monitor daemons. These have fixed IP addresses,
so they are often referenced by IP rather than hostname for
convenience, or to avoid relying on DNS. Using IPv4 addresses as the
host name works already, but IPv6 addresses require rbd-specific
escaping because the colon is used as an option separator in the
string passed to qemu.

Escape these colons, and enclose the IPv6 address in square brackets
so it is distinguished from the port, which is currently mandatory.

Acked-by: Osier Yang <jyang@redhat.com>
Signed-off-by: Josh Durgin <josh.durgin@inktank.com>
2013-01-25 11:48:24 +08:00

10 lines
468 B
Plaintext

LC_ALL=C PATH=/bin HOME=/home/test USER=test LOGNAME=test \
/usr/bin/qemu -S -M pc -m 214 -smp 1 -nographic -monitor \
unix:/tmp/test-monitor,server,nowait -no-acpi -boot c -usb -drive \
file=/dev/HostVG/QEMUGuest1,if=ide,bus=0,unit=0 -drive \
'file=rbd:pool/image:auth_supported=none:\
mon_host=[\:\:1]\:6321\;example.org\:6789\;\
[ffff\:1234\:567\:abc\:\:0f]\:6322\;\
[2001\:db8\:\:ff00\:42\:8329]\:6322,\
if=virtio,format=raw' -net none -serial none -parallel none