Summary: | Carp ipv6 duplicate address detection | ||
---|---|---|---|
Product: | Base System | Reporter: | Athanasios Douitsis <aduitsis> |
Component: | kern | Assignee: | freebsd-net (Nobody) <net> |
Status: | Open --- | ||
Severity: | Affects Some People | CC: | ae, dpetrov67, nicolas, stb, thomas |
Priority: | --- | Keywords: | needs-qa |
Version: | 10.3-RELEASE | ||
Hardware: | amd64 | ||
OS: | Any |
Description
Athanasios Douitsis
2016-11-22 16:18:49 UTC
@Athanasios Could you please attach a file containing the non-working and working configurations (ie: /etc/rc.conf, if specified there). Please also include the exact FreeBSD version (uname -a) output. (In reply to Kubilay Kocak from comment #1) Running FreeBSD 10.3-RELEASE-p11 #0: Mon Oct 24 18:49:24 UTC 2016 root@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64 on both nodes. This works (dead:beef instead of my real prefix): ifconfig_vmx0_ipv6="inet6 accept_rtadv dead:beef::60/64" ifconfig_vmx0_alias1="inet6 dead:beef::95/64 no_dad vhid 34 pass bar” dead:beef::60 is node0 and dead:beef::61 is node1. Both have dead:beef::95/64 as the common carp IPv6 address. Vhid 34 is randomly chosen. For IPv4, I'm using a different vhid and pass, just to be on the safe side. Removing the no_dad from ifconfig_vmx0_alias1 and rebooting the BACKUP node causes the problem to appear. Backup node will compain about DAD upon reboot, ifconfig will say dead:beef::95/64 duplicated, so it can't really be used. Afterwards, trying to manualy issue ifconfig inet6 dead:beef::95/64 vhid 34 pass bar will fail the first time, second time it will go through. Hello, FreeBSD 12.3-RELEASE The issue is still exist but in a strange way, only the first carp interface have duplicated flag, other interfaces didn't have it (of course interfaces are configured in same way) host1-master# ifconfig vlan6 vlan6: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=600703<RXCSUM,TXCSUM,TSO4,TSO6,LRO,RXCSUM_IPV6,TXCSUM_IPV6> ether aa:aa:aa:aa:aa:aa inet 192.168.0.2 netmask 0xffffff00 broadcast 192.168.0.255 inet 192.168.0.1 netmask 0xffffff00 broadcast 192.168.0.255 vhid 6 inet6 fe80::aaaa:aaaa:aaaa:aaaa%vlan6 prefixlen 64 scopeid 0xf inet6 aaaa:bbbb:cccc:1::2 prefixlen 64 inet6 aaaa:bbbb:cccc:1::1 prefixlen 64 duplicated vhid 6 groups: vlan carp: MASTER vhid 6 advbase 1 advskew 0 vlan: 106 vlanpcp: 0 parent interface: lagg0 media: Ethernet autoselect status: active nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> host1-master# ifconfig vlan7 vlan7: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=600703<RXCSUM,TXCSUM,TSO4,TSO6,LRO,RXCSUM_IPV6,TXCSUM_IPV6> ether aa:aa:aa:aa:aa:aa inet 192.168.1.2 netmask 0xffffff00 broadcast 192.168.1.255 inet 192.168.1.1 netmask 0xffffff00 broadcast 192.168.1.255 vhid 7 inet6 fe80::aaaa:aaaa:aaaa:aaaa%vlan7 prefixlen 64 scopeid 0x10 inet6 aaaa:bbbb:cccc:2::2 prefixlen 64 inet6 aaaa:bbbb:cccc:2::1 prefixlen 64 vhid 7 groups: vlan carp: MASTER vhid 7 advbase 1 advskew 0 vlan: 107 vlanpcp: 0 parent interface: lagg0 media: Ethernet autoselect host2-slave# ifconfig vlan6 vlan6: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=600703<RXCSUM,TXCSUM,TSO4,TSO6,LRO,RXCSUM_IPV6,TXCSUM_IPV6> ether bb:bb:bb:bb:bb:bb inet 192.168.0.3 netmask 0xffffff00 broadcast 192.168.0.255 inet 192.168.0.1 netmask 0xffffff00 broadcast 192.168.0.255 vhid 6 inet6 fe80::bbbb:bbbb:bbbb:bbbb%vlan6 prefixlen 64 scopeid 0xf inet6 aaaa:bbbb:cccc:1::3 prefixlen 64 inet6 aaaa:bbbb:cccc:1::1 prefixlen 64 vhid 6 groups: vlan carp: BACKUP vhid 6 advbase 1 advskew 100 vlan: 106 vlanpcp: 0 parent interface: lagg0 media: Ethernet autoselect status: active nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> host2-slave# ifconfig vlan7 vlan7: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=600703<RXCSUM,TXCSUM,TSO4,TSO6,LRO,RXCSUM_IPV6,TXCSUM_IPV6> ether bb:bb:bb:bb:bb:bb inet 192.168.1.3 netmask 0xffffff00 broadcast 192.168.1.255 inet 192.168.1.1 netmask 0xffffff00 broadcast 192.168.1.255 vhid 7 inet6 fe80::bbbb:bbbb:bbbb:bbbb%vlan7 prefixlen 64 scopeid 0x10 inet6 aaaa:bbbb:cccc:2::3 prefixlen 64 inet6 aaaa:bbbb:cccc:2::1 prefixlen 64 vhid 7 groups: vlan carp: BACKUP vhid 7 advbase 1 advskew 100 vlan: 107 vlanpcp: 0 parent interface: lagg0 media: Ethernet autoselect status: active nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> # As suggested by Athanasios, entering manually again the address make duplicated flag disappear and so IPv6 address working. host1-master# ifconfig vlan6 inet6 aaaa:bbbb:cccc:1::1 prefixlen 64 vhid6 host1-master# ifconfig vlan6 vlan6: flags=8943<UP,BROADCAST,RUNNING,PROMISC,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=600703<RXCSUM,TXCSUM,TSO4,TSO6,LRO,RXCSUM_IPV6,TXCSUM_IPV6> ether aa:aa:aa:aa:aa:aa inet 192.168.0.2 netmask 0xffffff00 broadcast 192.168.0.255 inet 192.168.0.1 netmask 0xffffff00 broadcast 192.168.0.255 vhid 6 inet6 fe80::aaaa:aaaa:aaaa:aaaa%vlan6 prefixlen 64 scopeid 0xf inet6 aaaa:bbbb:cccc:1::2 prefixlen 64 inet6 aaaa:bbbb:cccc:1::1 prefixlen 64 vhid 6 groups: vlan carp: MASTER vhid 6 advbase 1 advskew 0 vlan: 106 vlanpcp: 0 parent interface: lagg0 media: Ethernet autoselect status: active nd6 options=21<PERFORMNUD,AUTO_LINKLOCAL> host1-master# I saw this just the other day! Thought it was me going nuts. Will keep an eye out for it and note the circumstances next time, but it was on 12.3-STABLE I just ran into this myself, 12.4-stable; I have carp for ipv4, plus a custom script that configures the v6 VIP manually. I don't think I've seen this hehavior before, where the failover has this issue. I'll probably adjust my script to either wait a second or two, or watch out for the duplicate flag and simply try again. I couldn't find much documentation on the duplicate flag. As far as I can tell, it sticks and disables that address permanently. I would have expected that there would be a retry mechanism of some sort. You can use no_dad flag when you create vlan interface. We usually configure all addresses manually on carp interfaces and also use -auto_linklocal flag: # vlan416 carp_interfaces="${carp_interfaces} vlan416" ifconfig_vlan416="vlan 416 vlandev ${vlanif} mtu 1500" ifconfig_vlan416_ipv6="inet6 -auto_linklocal no_dad" ifconfig_vlan416_alias1="inet A.B.C.D/28 vhid N ${carp_args}" ifconfig_vlan416_alias2="inet6 XX:XX:XX:XX::1/64 vhid M ${carp_args}" ifconfig_vlan416_alias3="inet6 fe80::1/64 vhid M ${carp_args}" |