When to use auto negotiation on ethernet switches?

Hi Nagi-loon,

Auto-negotiation is enabled by default on all interfaces but only for advertised speeds.

In order to Enable auto-negotiation over all supported speed values you need to configure the interface speed to auto.

e.g.

SN2100 [standalone: master] (config) # sh interfaces ethernet 1/1

Eth1/1:

Admin state : Enabled

Operational state : Down

Last change in operational status: 0:05:11 ago (2 oper change)

Boot delay time : 0 sec

Description : N/A

Mac address : b8:59:9f:5b:d4:98

MTU : 1500 bytes (Maximum packet size 1522 bytes)

Fec : auto

Operational Fec : N/A

Flow-control : receive off send off

Supported speeds : 1G 10G 25G 40G 50G 56G 100G

Advertised speeds : 100G

Actual speed : Unknown

Auto-negotiation : Enabled

Width reduction mode : Unknown

Switchport mode : access

MAC learning mode : Enabled

Forwarding mode : inherited cut-through

Telemetry sampling: Disabled TCs: N/A

Telemetry threshold: Disabled TCs: N/A

Telemetry threshold level: N/A

Last clearing of “show interface” counters: Never

60 seconds ingress rate : 0 bits/sec, 0 bytes/sec, 0 packets/sec

60 seconds egress rate : 0 bits/sec, 0 bytes/sec, 0 packets/sec

The switch will auto-negotiate on 100G only. But now when I configure the speed to auto, you can see below that switch will auto-negotiate on all supported speeds and link comes up at 40G

SN2100 [standalone: master] (config) # interface ethernet 1/1 speed auto force

SN2100 [standalone: master] (config) # sh interfaces ethernet 1/1

Eth1/1:

Admin state : Enabled

Operational state : Up

Last change in operational status: 0:00:16 ago (3 oper change)

Boot delay time : 0 sec

Description : N/A

Mac address : b8:59:9f:5b:d4:98

MTU : 1500 bytes (Maximum packet size 1522 bytes)

Fec : auto

Operational Fec : no-fec

Flow-control : receive off send off

Supported speeds : 1G 10G 25G 40G 50G 56G 100G

Advertised speeds : 1G 10G 25G 40G 50G 56G 100G

Actual speed : 40G (auto)

Auto-negotiation : Enabled

Width reduction mode : Unknown

Switchport mode : access

MAC learning mode : Enabled

Forwarding mode : inherited cut-through

Telemetry sampling: Disabled TCs: N/A

Telemetry threshold: Disabled TCs: N/A

Telemetry threshold level: N/A

If the interface speed is set to auto, you cannot add it in Mlag port channel or regular port channel as it gives following error.

SN2100 [standalone: master] (config) # interface ethernet 1/1 mlag-channel-group 1 mode active

% Interface Eth1/1 must be configured only to one speed. Several speed values or “auto” option are not supported in mlag-channel-group.

Thanks,

Mellanox Support.

1 Like