On Fri, Aug 10, 2018 at 11:36:01AM +0200, Remi Locherer wrote: > On 2018-08-09 03:53, Carlos Cardenas wrote: > > On Mon, Aug 06, 2018 at 08:18:23PM -0700, Carlos Cardenas wrote: > > > Howdy. > > > > > > Attached is a patch from my work that started at g2k18 on adding > > > administrative knobs to our LACP driver. > > > > > > The driver now has a new ioctl (SIOCxTRUNKOPTS), which for now only > > > has options for LACP: > > > * Mode - Active or Passive (default Active) > > > * Timeout - Fast or Slow (default Slow) > > > * System Priority - 1(high) to 65535(low) (default 32768) > > > * Port Priority - 1(high) to 65535(low) (default 32768) > > > * IFQ Priority - 0 to NUM_QUEUES (default 6) > > > > > > At the moment, ifconfig only has options for lacpmode and lacptimeout > > > plumbed as those are the immediate need. > > > > > > The approach taken for the options was to make them on a "trunk" vs a > > > "port" as what's typically seen on various NOSes (JunOS, NXOS, etc...) > > > as it's uncommon for a host to have one link "Passive" and the other > > > "Active" in a given trunk. > > > > > > Just like on a NOS, when applying lacpmode or lacptimeout, the > > > settings > > > are immediately applied to all existing ports in the trunk and to all > > > future ports brought into the trunk. > > > > > > When using lacpmode/lacptimeout, they can be used on the same line > > > creating the trunk. > > > > > > Here's an example hostname.trunk0: > > > trunkproto lacp lacptimeout fast > > > trunkport em0 > > > trunkport em1 > > > dhcp > > > inet6 autoconf > > > > > > Testing done: > > > Arch - amd64 > > > - Kernel: bsd.rd and GENERIC.MP > > > - NIC Driver: em and oce > > > - NOS: JunOS 18.1 > > > - MLAG-SETUP: No > > > > > > I would like to solicit testers with additional NIC drivers, NOSes, > > > and > > > MLAG setups to ensure there's no regressions. > > > > > > Comments? Ok? > > > > I've updated the ifconfig piece to be a bit cleaner (prompted by > > deraadt). > > Hi Carlos, > > this works fine in my test. > > I used an APU1 (amd64) with re and a Ruckus ICX7150 (FI 08.0.80 switching). > With > active debug on the switch it's immediately visible when the timeout or mode > are > changed on the OpenBSD side: > > LACP RX(port=1/1/3,T=13774) -> PDU info > AC SP32768.000d.b935.3b41:PP32768.PN 3=K16 > (Pas/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > ^^^^^^ > PA SP1.903a.722a.2370:PP1.PN 3=K20 (Act/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > LACP RX(port=1/1/4,T=13774) -> PDU info > AC SP32768.000d.b935.3b41:PP32768.PN 2=K16 > (Pas/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > PA SP1.903a.722a.2370:PP1.PN 4=K20 (Act/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > LACP RX(port=1/1/3,T=14010) -> PDU info > AC SP32768.000d.b935.3b41:PP32768.PN 3=K16 > (Act/ST/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > ^^^^^^ > PA SP1.903a.722a.2370:PP1.PN 3=K20 (Act/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > LACP RX(port=1/1/4,T=14010) -> PDU info > AC SP32768.000d.b935.3b41:PP32768.PN 2=K16 > (Act/ST/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > PA SP1.903a.722a.2370:PP1.PN 4=K20 (Act/LT/Agg/SYN/Col/Dist/UN-Def/UN-Exp) > > Small nit: > In man trunk I would prefer when the defaults are listed in the lacp section > and > not in the caveats section. Your diff addresses the caveat ;-). > > OK remi >
Cool...I'll rework the manpage to reflect that before commit. +--+ Carlos