Bug 1275232 - RFE: Add ipv6 fe80 link address to the virtual interface automatically while start a ipv6 network
RFE: Add ipv6 fe80 link address to the virtual interface automatically while ...
Status: ASSIGNED
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: libvirt (Show other bugs)
7.2
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Ján Tomko
yalzhang@redhat.com
: FutureFeature
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-10-26 06:19 EDT by zhenfeng wang
Modified: 2017-11-22 07:51 EST (History)
9 users (show)

See Also:
Fixed In Version:
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description zhenfeng wang 2015-10-26 06:19:39 EDT
Description of problem:
while start a ipv6 virtual network, there will have a new virtual interface created in the pysical host which got a globel ipv6 address from the ipv6 network, however, the virtual interface won't got a link local address like fe80 address automatically, this will lead the guest fail to bind the ipv6 network during we start the guest which graphical buffer bind to ipv6 network

Version-Release number of selected component (if applicable):
libvirt-1.2.17-13.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.Prepare a xml for ipv6 network
#cat ipv6-net.xml
<network ipv6='yes'>
  <name>ipv6-net</name>
  <uuid>7ba66277-91b2-45b0-810b-f3620b924790</uuid>
  <forward mode='nat'/>
  <bridge name='virbr6' stp='on' delay='0'/>
  <mac address='52:54:00:46:07:af'/>
  <ip family='ipv6' address='2001:b8:ca2:2::1' prefix='64'>
    <dhcp>
      <range start='2001:b8:ca2:2:1::10' end='2001:b8:ca2:2:1::ff'/>
    </dhcp>
  </ip>
</network>


2.Define the network and start it, after start it, we could find the a new virtual interface created in the physcial host, however the interface have no linklocal address(fe80 address) assigned
#virsh define ipv6.xml
# virsh net-start ipv6-net
Network ipv6-net started

# ifconfifg
--

virbr6: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet6 2001:b8:ca2:2::1  prefixlen 64  scopeid 0x0<global>
        ether 52:54:00:46:07:af  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 0  bytes 0 (0.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

3.Start a guest which graphical buffer listen on ipv6 network, guest will fail to start since failed to initialize spice server

#virsh dumpxml rhel72
--
    <graphics type='spice' autoport='yes'>
      <listen type='network' network='ipv6-net'/>
    </graphics>

# virsh start rhel72
error: Failed to start domain rhel72
error: internal error: process exited while connecting to monitor: ((null):21135): Spice-Warning **: reds.c:3107:reds_init_socket: reds_init_socket: binding socket to 2001:b8:ca2:2::1:5900 failed
2015-10-15T09:24:31.904199Z qemu-kvm: failed to initialize spice server

Actual results:
Fail to start guest while the guest's graphical buffer bind to ipv6 network

Expected results:
1.if we could implement this new function that assign a fe80 link address to the virtual interface automatically, then we hope fix it, since it's a very useful function for the guest's graphics 

2.if we could't support it, please record it in doc, so that it won't confuse the consumer 

Additional info:
File this bug during review the following bug
https://bugzilla.redhat.com/show_bug.cgi?id=1192318
Comment 1 Thomas Huth 2016-01-26 07:17:03 EST
Could you try whether you get a link-local address when you use stp='off' instead of stp='on' in your ipv6-net.xml file?
Comment 2 zhenfeng wang 2016-01-27 00:55:16 EST
Hi Thomas
could get the link-local address successfully while use stp='off'

pkginfo
libvirt-1.2.17-13.el7_2.2.x86_64

steps
1.Prepare a ipv6 net
# cat ipv6-net.xml 
<network ipv6='yes'>
  <name>ipv6-net</name>
  <uuid>7ba66277-91b2-45b0-810b-f3620b924790</uuid>
  <forward mode='nat'/>
  <bridge name='virbr6' stp='off' delay='0'/>
  <mac address='52:54:00:46:07:af'/>
  <ip family='ipv6' address='2001:b8:ca2:2::1' prefix='64'>
    <dhcp>
      <range start='2001:b8:ca2:2:1::10' end='2001:b8:ca2:2:1::ff'/>
    </dhcp>
  </ip>
</network>

# virsh net-define ipv6-net.xml 
Network ipv6-net defined from ipv6-net.xml

# virsh net-start ipv6-net
Network ipv6-net started

2.check new created virtual interface, it could get link-local address
#ifconfig
--
virbr6: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        inet6 fe80::5054:ff:fe46:7af  prefixlen 64  scopeid 0x20<link>
        inet6 2001:b8:ca2:2::1  prefixlen 64  scopeid 0x0<global>
        ether 52:54:00:46:07:af  txqueuelen 0  (Ethernet)
        RX packets 0  bytes 0 (0.0 B)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 5  bytes 566 (566.0 B)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

3.Start a guest which graphical buffer listen on ipv6 network, guest could start successfully, also could connect guest's desktop with the assigned ipv6 address

#virsh dumpxml rhel7.1
--
    <graphics type='spice' autoport='yes'>
      <listen type='network' network='ipv6-net'/>
    </graphics>
    <graphics type='vnc' port='-1' autoport='yes'>
      <listen type='network' network='ipv6-net'/>
    </graphics>

# virsh start rhel7.1
Domain rhel7.1 started

#virsh dumpxml rhel7.1 
--
    <graphics type='spice' port='5900' autoport='yes' listen='2001:b8:ca2:2::1'>
      <listen type='network' address='2001:b8:ca2:2::1' network='ipv6-net'/>
    </graphics>
    <graphics type='vnc' port='5901' autoport='yes' listen='2001:b8:ca2:2::1'>
      <listen type='network' address='2001:b8:ca2:2::1' network='ipv6-net'/>
    </graphics>


#remote-viewer spice://[2001:b8:ca2:2::1]:5900
#remote-viewer vnc://[2001:b8:ca2:2::1]:5901

Note You need to log in before you can comment on or make changes to this bug.