Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Gentoo Linux bonding modes
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Vieri
l33t
l33t


Joined: 18 Dec 2005
Posts: 887

PostPosted: Wed Sep 29, 2021 1:15 pm    Post subject: Gentoo Linux bonding modes Reply with quote

Hi,

I'm using 3 NICs in balance-alb bonding mode.
It has been working fine for years, but now I'm about to change the stacked root switch where the Gentoo firewall is connected and I'd like to make sure I don't run into trouble.

From the bonding README file I can read:

Quote:
When a link is reconnected or a new slave joins the
bond the receive traffic is redistributed among all
active slaves in the bond by initiating ARP Replies
with the selected MAC address to each of the
clients. The updelay parameter (detailed below) must
be set to a value equal or greater than the switch's
forwarding delay so that the ARP Replies sent to the
peers will not be blocked by the switch.

updelay

Specifies the time, in milliseconds, to wait before enabling a
slave after a link recovery has been detected. This option is
only valid for the miimon link monitor. The updelay value
should be a multiple of the miimon value; if not, it will be
rounded down to the nearest multiple. The default value is 0.

miimon

Specifies the MII link monitoring frequency in milliseconds.
This determines how often the link state of each slave is
inspected for link failures. A value of zero disables MII
link monitoring. A value of 100 is a good starting point.
The use_carrier option, below, affects how the link state is
determined. See the High Availability section for additional
information. The default value is 0.


Now, I configure my network with Gentoo's /etc/conf.d/net file (sys-apps/openrc-0.42.1) with something like this:

Code:
config_lanixa="null"
config_lanma="null"
config_lanmb="null"
slaves_lan="lanixa lanma lanmb"
mode_lan="balance-alb"


The only parameters I set are the bonding mode and the slave interfaces.
The rest is set by the package, and here are a few values:

Code:
# cat /sys/class/net/lan/bonding/active_slave
lanma
# cat /sys/class/net/lan/bonding/arp_interval
0
# cat /sys/class/net/lan/bonding/downdelay
0
# cat /sys/class/net/lan/bonding/mii_status
up
# cat /sys/class/net/lan/bonding/miimon
100
# cat /sys/class/net/lan/bonding/mode
balance-alb 6
# cat /sys/class/net/lan/bonding/peer_notif_delay
0
# cat /sys/class/net/lan/bonding/slaves
lanixa lanma lanmb
# cat /sys/class/net/lan/bonding/updelay
0
# cat /sys/class/net/lan/bonding/use_carrier
1


What worries me is the README saying "The updelay value should be a multiple of the miimon value".
It also says "The updelay parameter must be set to a value equal or greater than the switch's forwarding delay".
I'm not sure how I can set/verify that value.
Is it the same as what's known as a "bridge forward delay" in a D-Link switch?

Is it safe to leave updelay as 0 (default)?

Regards,

Vieri
Back to top
View user's profile Send private message
Vieri
l33t
l33t


Joined: 18 Dec 2005
Posts: 887

PostPosted: Thu Oct 14, 2021 8:13 am    Post subject: Reply with quote

I've also noticed that when I add a Cisco Catalyst switch in the network I tend to get alerts and traffic blocking due to "MAC flapping". I guess it's because of the Gentoo Linux router using balance-alb.
I suppose I need to use LACP instead in this new environment unless the Cisco units' MAC flapping detection can be tweaked somehow.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum