vRouter vhost0 responds on ARP with MAC address of VM
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Juniper Openstack |
New
|
Undecided
|
Hari Prasad Killi | ||
OpenContrail |
New
|
High
|
Unassigned |
Bug Description
DHCP – instances did not received IP. CentOS and Windows machine only. It is caused by bad respond of vRouter MAC address of VM. VM dhcpclient reports that IP address is already used, so it declines offer.
It is OpenContrail build 7 days ago from branch R2.20 (github.
Bug Reproduction
I created network named "test", then launch instance with name "test-instance" with CentOS7. Instance get IP trough DHCP immediately. Then I add Route Target (64512:30) to network "test", restart network service in instance and do not get IP. Logs from instance:
DHCPDECLINE on eth0 to 255.255.255.255 port 67 (xid=0x5fd443e3)
oct 23 10:57:06 test-instance dhclient[1273]: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 3 (xid=0x62acb0d7)
oct 23 10:57:06 test-instance dhclient[1273]: DHCPREQUEST on eth0 to 255.255.255.255 port 67 (xid=0x62acb0d7)
oct 23 10:57:06 test-instance dhclient[1273]: DHCPOFFER from 10.0.152.34
oct 23 10:57:06 test-instance dhclient[1273]: DHCPACK from 10.0.152.34 (xid=0x1f39dfee)
oct 23 10:57:06 test-instance dhclient[1273]: DHCPDECLINE on eth0 to 255.255.255.255 port 67 (xid=0x62acb0d7)
tcpdump from tap interface on hypervisor:
11:54:43.587996 IP (tos 0x0, ttl 64, id 0, offset 0, flags [none], proto UDP (17), length 318)
10.0.152.34.67 > 10.0.152.36.68: [no cksum] BOOTP/DHCP, Reply, length 290, xid 0x5e3de243, Flags [none] (0x0000)
Your-IP 10.0.152.36
Server-IP 10.0.152.34
Magic Cookie 0x63825363
BR Option 28, length 4: 10.0.152.63
11:54:43.614120 ARP, Ethernet (len 6), IPv4 (len 4), Request who-has 10.0.152.36 (ff:ff:ff:ff:ff:ff) tell 0.0.0.0, length 28
11:54:43.614134 ARP, Ethernet (len 6), IPv4 (len 4), Reply 10.0.152.36 is-at 00:00:5e:00:01:00, length 28
11:54:43.615516 ARP, Ethernet (len 6), IPv4 (len 4), Request who-has 10.0.152.36 (ff:ff:ff:ff:ff:ff) tell 0.0.0.0, length 28
11:54:43.615524 ARP, Ethernet (len 6), IPv4 (len 4), Reply 10.0.152.36 is-at 00:00:5e:00:01:00, length 28
11:54:43.621239 IP (tos 0x10, ttl 128, id 0, offset 0, flags [none], proto UDP (17), length 328)
0.0.0.0.68 > 255.255.255.255.67: [udp sum ok] BOOTP/DHCP, Request from 02:ef:d4:b4:c4:61, length 300, xid 0x5e3de243, Flags [none] (0x0000)
Magic Cookie 0x63825363
I see that vRouter (00:00:5e:00:01:00) reply that it has required IP address, which is apparentaly wrong.
This behavior is seen just when route target is added in network. Immediately after I removed route target, everything starts work smoothly.
information type: | Proprietary → Public |
affects: | juniperopenstack → opencontrail |
Changed in opencontrail: | |
importance: | Undecided → High |
Changed in juniperopenstack: | |
assignee: | nobody → Hari Prasad Killi (haripk) |
tags: | added: vrouter |
Workaround on VM side e.g. CentOS is to modify /usr/sbin/ dhclient- script to disable arping
if arping -D -q -c2 -I "${interface}" "${new_ ip_address} "; then
dhconfig
exit_ with_hooks 0
dhconfig
exit_ with_hooks 0
exit_ with_hooks 1
else # DAD failed, i.e. address is already in use
# ARP_REPLY=$(arping -D -c2 -I "${interface}" "${new_ip_address}" | grep reply | awk '{print toupper($5)}' | #cut -d "[" -f2 | cut -d "]" -f1)
# OUR_MACS=$(ip link show | grep link | awk '{print toupper($2)}' | uniq)
# if [[ "${OUR_MACS}" = *"${ARP_REPLY}"* ]]; then
# # the reply can come from our system, that's OK (#1116004#c33)
# dhconfig
# exit_with_hooks 0
else
fi
fi