I have two interfaces em1 and em2. I use the following config:
ifconfig_lagg0="laggproto failover laggport em1 laggport em2 192.168.1.99 netmask 255.255.255.0" lagg0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM> ether 08:00:27:78:54:9e inet 192.168.1.99 netmask 0xffffff00 broadcast 192.168.1.255 media: Ethernet autoselect status: active laggproto failover laggport: em2 flags=0<> laggport: em1 flags=5<MASTER,ACTIVE>
When I ping 192.168.1.1 everything goes fine. I move to another console and take down the em1 interface
ifconfig em1 down ifconfig lagg0 ...same... laggport: em2 flags=4<ACTIVE> laggport: em1 flags=1<MASTER>
Ping 192.168.1.1 doesn't work anymore. I waited for some 5 minutes and it wouldn't budge. Then I brought em1 up. Hello sunshine ! It was working. Brought it down again - stopped working. What's more, I brought em0 up with some ip and it STILL wouldn't ping 192.168.1.1.
em0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500 options=9b<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM> ether 08:00:27:37:ca:72 inet 192.168.1.121 netmask 0xffffff00 broadcast 192.168.1.255 media: Ethernet autoselect (1000baseT <full-duplex>) status: active
So I start thinking freebsd gave up on me with a I-wont-ping-your-stupid-ip attitude. On 192.168.1.1 tcpdump shows it's pinging it (packets coming from 192.168.1.99). Back on freebsd it shows the same (it actually shows outgoing packets - from 192.168.1.99 - and orderly replies). But ping doesn't show ANYTHING, 100% packet loss wohooo. So I decide to really look into tcpdump.
I see icmp requests originating from 08:00:27:78:54:9e to the mac on 192.168.1.1. And I see icmp replies originating on 192.168.1.1 to the mac 08:00:27:78:54:9e. Then I see it's the MAC of em1 and lagg0.
So, although I took the interface down, it still sends packets with the same source mac. (And so it doesn't work in a very creative way. I can ping from 192.168.1.1 but not the other way around.
Mind you, the same happens when instead of taking down the interface I unplug the cable. This way I can't see how failover works. How can I solve this problem ? Any help is appreciated.