I use the following code run at host directly and in plugin container, it success in host, but failed in plugin container.
Here is code:
root@devstack:~# cat a.py
import pyroute2
ip = pyroute2.IPDB()
with ip.interfaces['tap1e510214-51'] as iface:
iface.add_ip('fd34:d27c:33d3:0:f816:3eff:fe3f:8693/64')
I find if I run the code in side plugin container, I see the IPV6 is setted on interface, but it is fd34:d27c:33d3::f816:3eff:fe3f:8693%32687/64, it is very strange that it has "%32687" there.
Here is output of ifconfig:
tap1e510214-51 Link encap:Ethernet HWaddr FE:DA:A6:93:E3:28
inet6 addr: fd34:d27c:33d3::f816:3eff:fe3f:8693%32687/64 Scope:Global
UP BROADCAST MTU:1500 Metric:1
RX packets:8 errors:0 dropped:0 overruns:0 frame:0
TX packets:7 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000
RX bytes:816 (816.0 B) TX bytes:738 (738.0 B)
I need to go on check why it has "%32687" in the IPV6 address.
@hongbin,
Here is what I find right now.
I use the following code run at host directly and in plugin container, it success in host, but failed in plugin container.
Here is code:
root@devstack:~# cat a.py
import pyroute2
ip = pyroute2.IPDB() 'tap1e510214- 51'] as iface: add_ip( 'fd34:d27c: 33d3:0: f816:3eff: fe3f:8693/ 64')
with ip.interfaces[
iface.
I find if I run the code in side plugin container, I see the IPV6 is setted on interface, but it is fd34:d27c: 33d3::f816: 3eff:fe3f: 8693%32687/ 64, it is very strange that it has "%32687" there.
Here is output of ifconfig: 33d3::f816: 3eff:fe3f: 8693%32687/ 64 Scope:Global
collisions: 0 txqueuelen:1000
tap1e510214-51 Link encap:Ethernet HWaddr FE:DA:A6:93:E3:28
inet6 addr: fd34:d27c:
UP BROADCAST MTU:1500 Metric:1
RX packets:8 errors:0 dropped:0 overruns:0 frame:0
TX packets:7 errors:0 dropped:0 overruns:0 carrier:0
RX bytes:816 (816.0 B) TX bytes:738 (738.0 B)
I need to go on check why it has "%32687" in the IPV6 address.