Bug 1253366

Summary: IPv6 is not initialized with qemu-kvm
Product: Red Hat Enterprise Linux 6 Reporter: Bill Sanford <bsanford>
Component: spice-serverAssignee: Default Assignee for SPICE Bugs <rh-spice-bugs>
Status: CLOSED NOTABUG QA Contact: SPICE QE bug list <spice-qe-bugs>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.7CC: astepano, bsanford, cfergeau, dblechte, djasa, mkenneth, pgrunt, rbalakri, tjamrisk, tpelka, vehrlich
Target Milestone: rc   
Target Release: 6.8   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-12-17 10:06:30 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Bill Sanford 2015-08-13 14:37:18 UTC
Description of problem:
IPv6 is not initialized with qemu-kvm. 

Version-Release number of selected component (if applicable):
RHEL-6.7-20150805.2 - base and optional - Host and client
Supp-6.7-RHEL-6-20150702.0 - Host and client

RHEL-6-20150702.0 - guest 
Firefox 38.0.1 - guest 

On the Host:
spice-glib-0.26-4.el6.x86_64
spice-gtk-devel-0.26-4.el6.x86_64
spice-gtk-python-0.26-4.el6.x86_64
spice-server-devel-0.12.4-12.el6.x86_64
spice-gtk-0.26-4.el6.x86_64
spice-protocol-0.12.6-1.el6.noarch
spice-glib-devel-0.26-4.el6.x86_64
spice-usb-share-4.9-9.el6.x86_64
spice-client-0.8.2-15.el6.x86_64
spice-server-0.12.4-12.el6.x86_64
spice-xpi-2.7-27.el6.x86_64
spice-vdagent-0.14.0-9.el6.x86_64
kmod-kspiceusb-rhel60-4.9-14.el6.x86_64
spice-gtk-tools-0.26-4.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
1.
2.
3.

Actual results:
IPv6 address does not get initialized with qemu

Expected results:
IPv6 address gets initialized with qemu

Additional info:

http://pastebin.test.redhat.com/305155

[root@unused-10-19-63-157 ~]# ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: wlan0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc mq state DOWN qlen 1000
    link/ether 9c:2a:70:69:23:a3 brd ff:ff:ff:ff:ff:ff
3: p3p2: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether b8:ca:3a:79:2a:de brd ff:ff:ff:ff:ff:ff
    inet 10.19.63.157/22 brd 10.19.63.255 scope global p3p2
    inet6 2620:52:0:133c:baca:3aff:fe79:2ade/64 scope global dynamic 
       valid_lft 2591609sec preferred_lft 604409sec
    inet6 fe80::baca:3aff:fe79:2ade/64 scope link 
       valid_lft forever preferred_lft forever
4: pan0: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN 
    link/ether 56:f4:43:64:84:80 brd ff:ff:ff:ff:ff:ff
5: virbr0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UNKNOWN 
    link/ether 52:54:00:a2:a7:c0 brd ff:ff:ff:ff:ff:ff
    inet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0
6: virbr0-nic: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN qlen 500
    link/ether 52:54:00:a2:a7:c0 brd ff:ff:ff:ff:ff:ff
[root@unused-10-19-63-157 ~]# /usr/libexec/qemu-kvm -spice port=3000,addr=2620:52:0:133c:baca:3aff:fe79:2ade%p3p2
(/usr/libexec/qemu-kvm:18392): Spice-Warning **: reds.c:3031:reds_init_socket: getaddrinfo(2620:52:0:133c:baca:3aff:fe79:2ade%p3p2,3000): Name or service not known
failed to initialize spice server[root@unused-10-19-63-157 ~]# 
[root@unused-10-19-63-157 ~]# /usr/libexec/qemu-kvm -spice port=3000,addr=2620:52:0:133c:baca:3aff:fe79:2ade\%p3p2
(/usr/libexec/qemu-kvm:18400): Spice-Warning **: reds.c:3031:reds_init_socket: getaddrinfo(2620:52:0:133c:baca:3aff:fe79:2ade%p3p2,3000): Name or service not known
failed to initialize spice server[root@unused-10-19-63-157 ~]# 
[root@unused-10-19-63-157 ~]#

Comment 2 Bill Sanford 2015-08-13 14:59:04 UTC
I also added the test case to the external tracker to verify that this is the correct usage of the command.

Comment 3 Christophe Fergeau 2015-08-13 15:47:30 UTC
Not very familiar with ipv6, but 
qemu-kvm -spice port=3000,fe80::baca:3aff:fe79:2ade%p3p2
should be working?

Comment 4 David Jaša 2015-08-14 14:25:29 UTC
(In reply to Christophe Fergeau from comment #3)
> Not very familiar with ipv6, but 
> qemu-kvm -spice port=3000,fe80::baca:3aff:fe79:2ade%p3p2
> should be working?

No. The device identifier (%p3p2) only needs to be appended to a link-local address - e.g. in Bill's case:
/usr/libexec/qemu-kvm -spice port=3000,addr=fe80::baca:3aff:fe79:2ade%p3p2

Global address works in as-is form:
/usr/libexec/qemu-kvm -spice port=3000,addr=2620:52:0:133c:baca:3aff:fe79:2ade

Comment 5 David Jaša 2015-08-14 14:26:39 UTC
Bill does it work for you according to comment 4?

Comment 6 Bill Sanford 2015-08-14 15:29:29 UTC
(In reply to David Jaša from comment #5)
> Bill does it work for you according to comment 4?

It does not initialize at all, according to comment 4.

Comment 7 Christophe Fergeau 2015-10-20 12:50:39 UTC
(In reply to Bill Sanford from comment #6)
> (In reply to David Jaša from comment #5)
> > Bill does it work for you according to comment 4?
> 
> It does not initialize at all, according to comment 4.

Please provide the exact command lines that you tried, this is working as expected on RHEL6.6/RHEL7/Fedora23 for me (as expected = what djasa explained in comment #4)

Comment 8 Pavel Grunt 2015-12-17 10:06:30 UTC
Bill, your address is not link-local so adding the device identifier / interface ID as a suffix will not work - explained in the comment 4.

If ipv6 does not work at all, please reopen the bug providing more info.

thanks

Comment 9 Bill Sanford 2016-01-19 14:24:48 UTC
When I see this without the local link, I will reopen.