Interface Configuration
Management Port
Section titled “Management Port”By default, the management port (mgmt 0) of the switch does not have an IP address when shipped from factory. It can automatically obtain IP address through DHCP by connecting the management port to DHCP Server on the same network segment. At the same time, AsterNOS supports users to manually configure the management port IP, which can only have one IPv4 address and one IPv6 address. Multiple configurations will be overwritten.
Management Port View
Section titled “Management Port View”Table 1 Management Port View
Command | Purpose |
---|---|
show interface mgmt | Display management port configuration. |
show interface mgmt
Section titled “show interface mgmt”[Command]
show interface mgmt
[Purpose]
Display management port configuration.
[View]
Privileged User View
[Use Cases]
sonic# show interface mgmtManagement IP address = 10.250.0.138/24Management Network Default Gateway = 10.250.0.254
Management Port Config
Section titled “Management Port Config”Table 2 Management Port Config
Command | Purpose |
---|---|
interface mgmt 0 | Enter Management Port Configuration View |
ip address A.B.C.D/M [gw A.B.C.D] | Configure or modify the IPv4 address and gateway of the management port. |
ipv6 address [A::B/M gw A::B] | Configure or modify the IPv6 address and gateway of the management port. |
interface mgmt 0
Section titled “interface mgmt 0”[Command]
interface mgmt 0
[Purpose]
Enter Management Port Configuration View
[View]
Global Configuration View
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0
ip address A.B.C.D/M [gw A.B.C.D]
Section titled “ip address A.B.C.D/M [gw A.B.C.D]”[Command]
ip address A.B.C.D/M [gw A.B.C.D]
[Purpose]
Configure or modify the IPv4 address and gateway of mgmt.
[Parameters]
Parameter | Description |
---|---|
A.B.C.D/M | IPv4 address with prefix length. |
A.B.C.D | (Optional) IPv4 gateway address without prefix length. |
[View]
Management Port Configuration View
[Notes]
IPv4 address with subnet mask /32 is not allowed to be configured. Addresses with subnet mask /31 is allowed. In other subnet masks, addresses with the host portion all-zeros or all-ones are not allowed. Run command no ip address A.B.C.D/M [gw A.B.C.D] to delete IPv4 address configuration of mgmt.
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0sonic(config-mgmt-0)# ip address 10.250.0.103/24 gw 10.250.0.254
ipv6 address [A::B/M gw A::B]
Section titled “ipv6 address [A::B/M gw A::B]”[Command]
ipv6 address A::B/M [gw A::B]
[Purpose]
Configure or modify the IPv6 address and gateway of mgmt.
[Parameters]
Parameter | Description |
---|---|
A::B/M | IPv6 address with prefix length. |
A::B | (Optional) IPv6 gateway address without prefix length. |
[View]
Management Port Configuration View
[Notes]
IPv6 address with subnet mask /127 or /128 is not allowed to be configured. In other subnet masks, addresses with the host portion all-zeros are not allowed, but all-ones are allowed. Run command no ip address A.B.C.D/M [gw A.B.C.D] to delete IPv6 address configuration of mgmt.
[Use Cases]
sonic# configure terminalsonic(config)# interface mgmt 0sonic(config-mgmt-0)# ipv6 address 2013::138/64 gw 2013::1
Interface Attribute Information
Section titled “Interface Attribute Information”Interface Attribute Information View
Section titled “Interface Attribute Information View”Table 3 Interface Attribute Information View
Command | Purpose |
---|---|
show interface description | Display description of interfaces. |
show interface description
Section titled “show interface description”[Command]
show interface description
[Purpose]
Display description of interfaces.
[View]
Privileged User View
[Use Cases]
sonic# show interface description Interface Oper Admin Alias Description--------------- ------ ------- ------- ------------- 0/0 down up Y1 N/A 0/1 down up Y2 N/A 0/2 down up Y3 N/A 0/3 down up Y4 N/A 0/4 down up Y5 N/A 0/5 down up Y6 N/A 0/6 down up Y7 N/A 0/7 down up Y8 N/A 0/8 down up Y9 N/A 0/9 down up Y10 N/A
Interface Status
Section titled “Interface Status”Interface Status View
Section titled “Interface Status View”Table 4 Interface Status View
Command | Purpose |
---|---|
show interface summary | Display summary information about the status of interfaces. |
show {ip|ipv6} interfaces | Display IP address configuration of interfaces. |
show interface [ethernet interface_name] | Display information about the status of interfaces. |
show counters interface [ethernet interface_name] | Display statistics of interfaces. |
show counters rif [{ethernet|vlan|link-aggregation} interface_name] | Display statistics of Layer 3 ports. |
clear counters {interface|rif} | Clear the counters. |
show link-delay | Display interface linkup delay configuration. |
show port-isolate summary | Display the port isolation group configuration. |
show interface startup_delay | Display the delayed startup time configuration of ports. |
show interface summary
Section titled “show interface summary”[Command]
show interface summary
[Purpose]
Display summary information about the status of interfaces.
[View]
Privileged User View
[Notes]
trunk indicates Layer 2 interface mode, routed indicates Layer 3 interface mode.
[Use Cases]
sonic# show interface summary Interface Lanes Speed MTU FEC Alias Vlan Oper Admin Type Asym PFC--------------- ----------- ------- ----- ----- ------- --------------- ------ ------- --------------- ---------- 0/0 0 25G 9216 rs Y1 lag1 up up SFP/SFP+/SFP28 N/A 0/1 1 25G 9216 rs Y2 routed down up N/A N/A 0/2 2 25G 9216 rs Y3 routed down up N/A N/A 0/3 3 25G 9216 rs Y4 routed down up N/A N/A 0/4 4 25G 9216 rs Y5 routed up up SFP/SFP+/SFP28 N/A 0/5 5 25G 9216 rs Y6 routed down up N/A N/A 0/6 6 25G 9216 rs Y7 routed down up N/A N/A 0/7 7 25G 9216 rs Y8 routed down up N/A N/A 0/8 8 25G 9216 rs Y9 routed down up N/A N/A 0/9 9 25G 9216 rs Y10 routed down up N/A N/A 0/10 10 25G 9216 rs Y11 routed up up SFP/SFP+/SFP28 N/A 0/11 11 25G 9216 rs Y12 routed down up SFP/SFP+/SFP28 N/A 0/12 12 25G 9216 rs Y13 routed down up N/A N/A 0/13 13 25G 9216 rs Y14 routed down up N/A N/A 0/14 14 25G 9216 rs Y15 routed down up SFP/SFP+/SFP28 N/A 0/15 15 25G 9216 rs Y16 routed down up N/A N/A 0/16 16 25G 9216 rs Y17 routed down up SFP/SFP+/SFP28 N/A 0/17 17 25G 9216 rs Y18 routed down up N/A N/A 0/18 18 25G 9216 rs Y19 routed down up N/A N/A 0/19 19 25G 9216 rs Y20 routed down up N/A N/A 0/20 20 25G 9216 rs Y21 routed down up N/A N/A 0/21 21 25G 9216 rs Y22 routed down up N/A N/A 0/22 22 25G 9216 rs Y23 routed down up N/A N/A 0/23 23 25G 9216 rs Y24 routed down up N/A N/A 0/24 24 25G 9216 rs Y25 routed down up N/A N/A 0/25 25 25G 9216 rs Y26 routed up up SFP/SFP+/SFP28 N/A 0/26 26 25G 9216 rs Y27 routed down up N/A N/A 0/27 27 25G 9216 rs Y28 routed down up N/A N/A 0/28 28 25G 9216 rs Y29 trunk down up N/A N/A 0/29 29 25G 9216 rs Y30 trunk down up N/A N/A 0/30 30 25G 9216 rs Y31 routed down up N/A N/A 0/31 31 25G 9216 rs Y32 routed down up N/A N/A 0/32 32 25G 9216 rs Y33 routed up up SFP/SFP+/SFP28 N/A 0/33 33 25G 9216 rs Y34 routed down up N/A N/A 0/34 34 25G 9216 rs Y35 routed down up N/A N/A 0/35 35 25G 9216 rs Y36 routed down up N/A N/A 0/36 36 25G 9216 rs Y37 routed down up N/A N/A 0/37 37 25G 9216 rs Y38 routed down up N/A N/A 0/38 38 25G 9216 rs Y39 routed down up SFP/SFP+/SFP28 N/A 0/39 39 25G 9216 rs Y40 routed down up N/A N/A 0/40 40 25G 9216 rs Y41 routed down up N/A N/A 0/41 41 25G 9216 rs Y42 routed down up N/A N/A 0/42 42 25G 9216 rs Y43 routed down up N/A N/A 0/43 43 25G 9216 rs Y44 routed down up N/A N/A 0/44 44 25G 9216 rs Y45 routed down up N/A N/A 0/45 45 25G 9216 rs Y46 routed down up N/A N/A 0/46 46 25G 9216 rs Y47 routed down up N/A N/A 0/47 47 25G 9216 rs Y48 routed down up SFP/SFP+/SFP28 N/A 0/48 48,49,50,51 100G 9216 rs C1 routed up up QSFP28 or later N/A 0/52 52,53,54,55 100G 9216 rs C2 lag99 down up QSFP28 or later N/A 0/56 56,57,58,59 100G 9216 rs C3 routed down up QSFP28 or later N/A 0/60 64,65,66,67 100G 9216 rs C4 routed up up QSFP28 or later N/A 0/64 68,69,70,71 100G 9216 rs C5 routed up up QSFP28 or later N/A 0/68 72,73,74,75 100G 9216 rs C6 routed down up N/A N/A 0/72 76,77,78,79 100G 9216 rs C7 routed up up QSFP28 or later N/A 0/76 80,81,82,83 100G 9216 rs C8 routed down up N/A N/A lag1 N/A 25G 9216 N/A N/A trunk up up N/A N/A lag99 N/A 100G 9216 N/A N/A trunk down up N/A N/A
show {ip|ipv6} interfaces
Section titled “show {ip|ipv6} interfaces”[Command]
show {ip|ipv6} interfaces
[Purpose]
Display IP address configuration of interfaces.
[View]
Privileged User View
[Use Cases]
sonic# show ip interfacesInterface Master IPv4 address/mask Admin/Oper BGP Neighbor Neighbor IP----------- -------- ------------------- ------------ -------------- -------------0/48 199.0.3.1/24 up/up N/A N/A0/52 199.0.7.1/24 up/up N/A N/A0/72 10.72.0.1/24 up/up N/A N/Aloopback0 10.1.0.34/32 up/up N/A N/Avlan100 Vrf123 100.100.0.1/24 up/up N/A N/Avlan200 Vrf123 200.200.0.1/24 up/up N/A N/Avlan300 Vrf123 200.230.0.1/24 up/down N/A N/Avlan400 200.240.0.1/24 up/down N/A N/Avlan4094 99.0.0.1/24 up/up N/A N/Amgmt 10.250.0.138/24 up/up N/A N/Asonic# show ipv6 interfacesInterface Master IPv6 address/mask Admin/Oper BGP Neighbor Neighbor IP----------- -------- ------------------- ------------ -------------- -------------0/48 2000::1/64 up/up N/A N/A
show interface [ethernet interface_name]
Section titled “show interface [ethernet interface_name]”[Command]
show interface [ethernet interface_name]
[Purpose]
Display information about the status of interfaces.
[Parameters]
Parameter | Description |
---|---|
interface_name | Interface name (eg.0/1) |
[View]
Privileged User View
[Use Cases]
sonic# show interface ethernet 0/2080/208 is up, line protocol is upHardware is EthMac address is 60:eb:5a:01:34:cfInterface index is 208Description is N/AMode of IPV4 address assignment: not-setMode of IPV6 address assignment: not-setIP MTU 9216 bytesLineSpeed 100.0G, Auto-negotiation offInput statistics: 421 packets, 108,425 octets 414 Multicasts, 3 Broadcasts, 4 Unicasts 0 error, 0 discarded, 2 crc-errorOutput statistics: 1,207,984,068 packets, 154,622,078,263 octets 454 Multicasts, 5 Broadcasts, 1,207,983,609 Unicasts 0 error, 3,322 discarded
show counters interface [ethernet interface_name]
Section titled “show counters interface [ethernet interface_name]”[Command]
show counters interface [ethernet interface_name]
[Purpose]
Display statistics of interfaces.
[Parameters]
Parameter | Description |
---|---|
interface_name | Interface name (eg.0/1) |
[View]
Privileged User View
[Use Cases]
sonic# show counters interfaces IFACE STATE RX_OK RX_BPS RX_UTIL RX_ERR RX_DRP RX_OVR TX_OK TX_BPS TX_UTIL TX_ERR TX_DRP TX_OVR--------------- ------- ------- -------- --------- -------- -------- -------- ------- -------- --------- -------- -------- -------- Ethernet0 D 0 N/A N/A 0 0 0 0 N/A N/A 0 0 N/A Ethernet1 U 0 N/A N/A 0 0 0 27 N/A N/A 0 0 N/A Ethernet2 U 0 N/A N/A 0 0 0 27 N/A N/A 0 0 N/A Ethernet3 U 0 N/A N/A 0 0 0 35 N/A N/A 0 0 N/A Ethernet4 X 0 N/A N/A 0 0 0 0 N/A N/A 0 0 N/Asonic# show counters interfaces ethernet 0/1Port: 0/1 Rx 1024to1518Pkts : 0 Rx 128-255Pkts : 0 Rx 1519to2047Pkts : 0 Rx 2048to4095Pkts : 0 Rx 256-511Pkts : 0 Rx 4096to9216Pkts : 0 Rx 512-1023Pkts : 0 Rx 64Pkts : 0 Rx 65-127Pkts : 0 Rx 9217to16383Pkts : 0 Rx Bcast : 0 Rx Bytes : 0 Rx CRC Alignment : 0 Rx Err : 0 Rx Mcast : 0 Rx Oversize : 0 Rx Pkts : 0 Rx Ucast : 0 Rx UnderSize : 0 Tx 1024to1518Pkts : 0 Tx 128-255Pkts : 9032 Tx 1519to2047Pkts : 0 Tx 2048to4095Pkts : 0 Tx 256-511Pkts : 0 Tx 4096to9216Pkts : 0 Tx 512-1023Pkts : 0 Tx 64Pkts : 0 Tx 65-127Pkts : 51 Tx 9217to16383Pkts : 0 Tx Bcast : 0 Tx Bytes : 1833670 Tx Err : 0 Tx Mcast : 9083 Tx Oversize : 0 Tx Pkts : 9083 Tx Ucast : 0
show counters rif [{ethernet|vlan|link-aggregation} interface_name]
Section titled “show counters rif [{ethernet|vlan|link-aggregation} interface_name]”[Command]
show counters rif [{ethernet|vlan|link-aggregation} interface_name]
[Purpose]
Display statistics of Layer 3 ports.
[Parameters]
Parameter | Description |
---|---|
interface_name | Interface name (eg.0/1) |
[View]
Privileged User View
[Use Cases]
sonic# show counters rif IFACE RX_OK RX_BPS RX_PPS RX_ERR TX_OK TX_BPS TX_PPS TX_ERR----------- ------- -------- -------- -------- ------- -------- -------- -------- 0/1 N/A N/A N/A N/A N/A N/A N/A N/A0/1.1 N/A N/A N/A N/A N/A N/A N/A N/A 0/48 N/A N/A N/A N/A N/A N/A N/A N/A
clear counters {interface|rif}
Section titled “clear counters {interface|rif}”[Command]
clear counters {interface|rif}
[Purpose]
Clear the counters.
[Parameters]
Parameter | Description |
---|---|
interface | Clear counters of all interfaces. |
rif | Clear counters of router interfaces. |
[View]
Privileged User View
[Use Cases]
sonic# clear counters interfaceCleared counters
show link-delay
Section titled “show link-delay”[Command]
show link-delay
[Purpose]
Display interface linkup delay configuration.
[View]
Privileged User View
[Use Cases]
sonic# show link-delayPort up delay : 5
show port-isolate summary
Section titled “show port-isolate summary”[Command]
show port-isolate summary
[Purpose]
Display the port isolation group configuration.
[View]
Privileged User View
[Use Cases]
sonic# show port-isolate summary+----------------+--------+-----------------------+-----------------------+| Isolate Name | Type | Isolated from | Isolated to |+================+========+=======================+=======================+| test1 | port | 0/42 ,0/40 | 0/42 ,0/40 |+----------------+--------+-----------------------+-----------------------+
show interface startup_delay
Section titled “show interface startup_delay”[Command]
show interface startup_delay
[Purpose]
Display the delayed startup time configuration of ports.
[View]
Privileged User View
[Use Cases]
sonic# show interface startup_delay Port start up delay time----------- --------------------- 0/0 150 0/4 150 0/8 150 0/12 150 0/16 150 0/20 150 0/24 150 0/28 150 0/32 150 0/36 150 0/40 150 0/44 150 0/48 150 ......
Interface Status Config
Section titled “Interface Status Config”Table 5 Interfaces Status Config
Command | Purpose |
---|---|
interface ethernet interface_name | Enter Physical Interface Configuration View. |
shutdown | Bring the interface down administratively. |
speed speed | Set the speed for physical interfaces. |
autoneg | Enable autonegotiation of interfaces. |
advertised-speeds {speed|all} | Configure autonegotiation of interfaces speed |
ip address {A.B.C.D/M|A::B/M} [secondary] | Configure IP address for the interface. |
fec {fc|rs} | Set FEC mode of interfaces. |
mtu mtu | Configure the MTU value on an interface. |
description description | Specify the description for the interface. |
mac_address HH:HH:HH:HH:HH:HH | Specify a MAC address to the Layer 3 interface. |
mac-address learning | Enable MAC learning for the interface. |
switchport | Change a Layer 3 interface into a Layer 2 interface. |
switchport {trunk|access} vlan vlan-id | Add the interface to a vlan. |
switchport range vlan min-id max-id | Add the interface to bulk VLANs. |
link-delay up delay-time | Set a delay time for interface state from down to up. |
monitor-link group-name {uplink|downlink} | Configure uplink and downlink. |
breakout {4x25G[10G]|4x50G[10G]|2x200G[100G]|4x100G[50G]|2x100G[50G]|4x200G[100G]| 2x400G[200G]} | Split high bandwidth ports into four low speed ports. |
startup-delay delay-time | Set a delay time for interface state from down to up during system startup. |
port-isolate enable isloate-group-name | Create a port isolation group. |
loopback-pkt-drop | Enable the loopback packets not forwarding feature. |
ipv6 use-link-local | Enable the IPv6 link local address function of the interface |
interface ethernet interface_name
Section titled “interface ethernet interface_name”[Command]
interface ethernet interface_name
[Purpose]
Enter Physical Interface Configuration View.
[Parameters]
Parameter | Description |
---|---|
interface_name | Interface name (eg.0/1) |
[View]
Global Configuration View
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# show this!interface ethernet 0/1
shutdown
Section titled “shutdown”[Command]
shutdown
[Purpose]
Bring the interface down administratively.
[View]
Physical Interface Configuration View
[Notes]
Run command no shutdown to bring the interface up administratively.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# shutdownsonic(config-if-0/1)# show this!interface ethernet 0/1shutdown
speed speed
Section titled “speed speed”[Command]
speed speed
[Purpose]
Set the speed for physical interfaces.
[Parameters]
Parameter | Description |
---|---|
speed | The speed is in Mbit. 1000/10000/25000/25000-R1/40000/50000-R1/50000-R2/100000/100000-R1/100000-R2/200000/200000-R2/200000-R4/400000/400000-R4/400000-R8/800000 are available. |
[View]
Physical Interface Configuration View
[Notes]
When modifying the speed, if it does not match current FEC mode, system will give a prompt that you need to modify the FEC mode first. The FEC mode support for different speeds is as follows: 1GE/10GE interfaces do not support FEC, 25GE/100GE interfaces support fc and rs modes, and 40GE interfaces only support fc mode, 200GE/400GE interfaces only support rs mode. 100000-R2 means 100G rate mode for two lanes, which only supported by CX732Q-N and CX864E-N. The 25000-R1/50000-R1/50000-R2/100000-R1/100000-R4/200000-R2/200000-R4/400000-R4/400000-R8/800000 rate modes are only supported on CX864E-N for configuration.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# speed 10000sonic(config-if-0/1)# show this!interface ethernet 0/1 speed 10000
autoneg
Section titled “autoneg”[Command]
autoneg
[Purpose]
Enable autonegotiation of interfaces.
[View]
Physical Interface Configuration View
[Notes]
Run command no autoneg to disable autonegotiation.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/1)# autonegsonic(config-if-0/1)# show this!interface ethernet 0/2autoneg
advertised-speeds {speed|all}
Section titled “advertised-speeds {speed|all}”[Command]
advertised-speeds {speed|all}
[Purpose]
Configure autonegotiation of interfaces rate.
[Parameters]
Parameter | Description |
---|---|
speed | Specify autonegotiation of interfaces rate |
all | All speeds supported by the interface |
[View]
Physical Interface Configuration View
[Notes]
After configuring autonegotiation of interfaces rate, run command no autoneg and autoneg commands to take effect. Run command no advertised-speeds to delete autonegotiation of interfaces rate.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/2)# advertised-speeds 40000Notice: advertised_speed is set success, please operate autoneg off and on to enable advertised_speed become effective
ip address {A.B.C.D/M|A::B/M} [secondary]
Section titled “ip address {A.B.C.D/M|A::B/M} [secondary]”[Command]
ip address {A.B.C.D/M|A::B/M} [secondary]
[Purpose]
Configure IP address for the interface.
[Parameters]
Parameter | Description |
---|---|
A.B.C.D/M | IPv4 address with prefix length. |
A::B/M | IPv6 address with prefix length. |
secondary | The default is Primary IP, specifying this option means configuring as Secondary IP, which requires that the Secondary IP and Primary IP be in the same network segment. |
[View]
Physical Interface Configuration View
[Notes]
IPv4 address with subnet mask /32 is not allowed to be configured. Addresses with subnet mask /31 is allowed. In other subnet masks, addresses with the host portion all-zeros or all-ones are not allowed. IPv6 address with subnet mask /127 or /128 is not allowed to be configured. In other subnet masks, addresses with the host portion all-zeros are not allowed, but all-ones are allowed. Run command no ip address {A.B.C.D/M|A::B/M} [secondary] to delete IP address configuration.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/1)# ip address 3.3.3.6/24sonic(config-if-0/1)# show this!interface ethernet 0/2ip address 3.3.3.6/24
fec {fc|rs}
Section titled “fec {fc|rs}”[Command]
fec {fc|rs}
[Purpose]
Set FEC mode of interfaces.
[View]
Physical Interface Configuration View
[Notes]
1GE/10GE ports do not support FEC, 25GE/100GE ports support fc and rs modes. 40GE ports on CX308P-48Y-N-V2 support fc mode, and other models do not support FEC, 200G/400G/800G interfaces only support rs mode, 400G interface on CX732Q-N and CX732Q-N-V2 supports disabling FEC after slowing down to 100G rate. Run command no fec to disable FEC.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# fec rs
mtu mtu
Section titled “mtu mtu”[Command]
mtu mtu
[Purpose]
Configure the MTU value on an interface.
[Parameters]
Parameter | Description |
---|---|
mtu | Maximum Transmission Unit, the range is from 1312 to 9216. |
[View]
Physical Interface Configuration View
[Notes]
The default is 9216 Bytes.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# mtu 1518sonic(config-if-0/1)# show this!interface ethernet 0/1 mtu 1518
description description
Section titled “description description”[Command]
description description
[Purpose]
Specify the description for the interface.
[Parameters]
Parameter | Description |
---|---|
description | In string form. |
[View]
Physical Interface Configuration View
[Notes]
Run command no description to delete description.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1sonic(config-if-0/1)# description abcsonic(config-if-0/1)# show this!interface ethernet 0/1 description abc
mac_address HH:HH:HH:HH:HH:HH
Section titled “mac_address HH:HH:HH:HH:HH:HH”[Command]
mac_address HH:HH:HH:HH:HH:HH
[Purpose]
Specify a MAC address to the Layer 3 interface.
[Parameters]
Parameter | Description |
---|---|
HH:HH:HH:HH:HH:HH | MAC address, not case sensitive. |
[View]
Physical Interface Configuration View
[Notes]
The default is the MAC of the switch; Run command no mac_address to restore the MAC of the Layer 3 interface to default.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/2)# mac-address 18:17:25:37:67:afsonic(config-if-0/2)# show this!interface ethernet 0/2 mac-address 18:17:25:37:67:af
mac-address learning
Section titled “mac-address learning”[Command]
mac-address learning
[Purpose]
Enable MAC learning for the interface.
[View]
Physical Interface Configuration View
[Notes]
The interface to be operated should be added to a VLAN. MAC learning is enabled by default. Run command no mac-address learning to disable MAC learning for the interface.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/2)# no mac-address learningsonic(config-if-0/2)# show this!interface ethernet 0/2 no mac-address learning
switchport
Section titled “switchport”[Command]
switchport
[Purpose]
Change a Layer 3 interface into a Layer 2 interface.
[View]
Physical Interface Configuration View
[Notes]
Run command no switchport to change a Layer 2 interface into a Layer 3 interface.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2sonic(config-if-0/2)# switchportsonic(config-if-0/2)# show this!interface ethernet 0/2switchportsonic(config-if-0/2)# no switchportsonic(config-if-0/2)# show this!interface ethernet 0/2
switchport {trunk|access} vlan vlan-id
Section titled “switchport {trunk|access} vlan vlan-id”[Command]
switchport {trunk|access} vlan vlan-id
[Purpose]
Add the interface to a vlan.
[Parameters]
Parameter | Description |
---|---|
access | Add to VLAN as untagged. |
trunk | Add to VLAN as tagged. |
vlan-id | VLAN ID, the range is [1,4094]. |
[View]
Physical Interface Configuration View
[Notes]
An interface can only be added to one VLAN as untagged, but it can be added to multiple VLANs as tagged. The VLAN ID of the untagged VLAN will be set as PVID of the interface; Run command no switchport vlan vlan-id to remove the interface from specified VLAN; Run command no switchport to remove the interface from all VLANs and change to Layer 3 port.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# switchport access vlan 300sonic(config-if-0/0)# show this!interface ethernet 0/0 switchport access vlan 300
switchport range vlan min-id max-id
Section titled “switchport range vlan min-id max-id”[Command]
switchport range vlan min-id max-id
[Purpose]
Add the interface to bulk VLANs.
[Parameters]
Parameter | Description |
---|---|
min-id | Starting VLAN ID, the range is [1,4094]. |
max-id | Ending VLAN ID, the range is [1,4094]. |
[View]
Physical Interface Configuration View/LAGIF Configuration View
[Notes]
Run command no switchport vlan range min-id max-id to remove the interface from bulk VLANs.
[Use Cases]
sonic# configure terminalsonic(config)# vlan range 10 20sonic(config)# interface ethernet 0/4sonic(config-if-0/4)# switchport range vlan 10 20
link-delay up delay-time
Section titled “link-delay up delay-time”[Command]
link-delay up delay-time
[Purpose]
Set a delay time for interface state from down to up.
[Parameters]
Parameter | Description |
---|---|
delay-time | The delay time is in seconds and takes the value in the range 0 or [2-10]. The default is 0. |
[View]
Global Configuration View
[Notes]
The purpose is that when the operation status of an interface goes from down to up, the interface will go through a delay time before going up again. This function is disabled on interfaces by default.
[Use Cases]
sonic# configure terminalsonic(config)# link-delay up 2
monitor-link group-name {uplink|downlink}
Section titled “monitor-link group-name {uplink|downlink}”[Command]
monitor-link group-name {uplink|downlink}
[Purpose]
Configure uplink and downlink.
[Parameters]
Parameter | Description |
---|---|
group-name | Specify the monitor-link group name. |
[View]
Physical Interface Configuration View
[Notes]
Run command no monitor-link group-name to delete monitor-link interface configuration.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# monitor-link test downlink
breakout {4x25G[10G]|4x50G[10G]|2x200G[100G]|4x100G[50G]|2x100G[50G]|4x200G[100G]| 2x400G[200G]}
Section titled “breakout {4x25G[10G]|4x50G[10G]|2x200G[100G]|4x100G[50G]|2x100G[50G]|4x200G[100G]| 2x400G[200G]}”[Command]
breakout {4x25G[10G]|4x50G[10G]|2x200G[100G]|4x100G[50G]|2x100G[50G]|4x200G[100G]|2x400G[200G]}
[Purpose]
Split high bandwidth ports into four low speed ports.
[Parameters]
Parameter | Description |
---|---|
4x25G[10G] | Split into four 25G ports, supported on 100GE、200GE、400GE ports. |
4x50G[10G] | Split into four 50G ports, supported on 200GE ports. |
2x200G[100G] | Split into two 200G ports, supported on 400GE ports. |
4x100G[50G] | Split into four 100G ports, supported on 400GE ports. |
2x100G[50G] | Split into two 50G ports, supported on 200GE ports. |
4x200G[100G] | Split into four 200G ports, supported on 800GE ports. |
2x400G[200G] | Split into two 400G ports, supported on 800GE ports. |
[View]
Physical Interface Configuration View
[Notes]
Please delete the configuration related to this interface before breakout. The system will give a prompt after the breakout is successful. Run command no breakout undoes the breakout configuration.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# breakout 4x25G[10G]Start to breakout. Do not interrupt the breakout; otherwise, the configuration may be abnormal!Breakout process got successfully completed.Please note loaded setting will be lost after system reboot. To preserve setting, run write.
startup-delay delay-time
Section titled “startup-delay delay-time”[Command]
startup-delay delay-time
[Purpose]
Set a delay time for interface state from down to up during system startup.
[Parameters]
Parameter | Description |
---|---|
delay-time | The delay time is in seconds and takes the range is from 1 to 65535. |
[View]
Physical Interface Configuration View
[Notes]
Run command no startup-delay to delete interface startup-delay configuration.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# startup-delay 150
port-isolate enable isloate-group-name
Section titled “port-isolate enable isloate-group-name”[Command]
port-isolate enable isloate-group-name
[Purpose]
Create a port isolation group.
[Parameters]
Parameter | Description |
---|---|
isloate-group-name | Port isolation group name. |
[View]
Physical Interface Configuration View
[Notes]
Currently only supported on CX308P-48Y-N-V2 and CX532P-N-V2. The ports in the isolation group are bi-directionally isolated. Run command no port-isolate enable to delete the port isolation group.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/42sonic(config-if-0/42)# port-isolate enable test1sonic(config-if-0/42)# show this!interface ethernet 0/42 fec rs mtu 9216 port-isolate enable test1 speed 25000
loopback-pkt-drop
Section titled “loopback-pkt-drop”[Command]
loopback-pkt-drop
[Purpose]
Enable the loopback packets not forwarding feature.
[View]
Physical Interface Configuration View
[Notes]
Currently not supported on CX308P-48Y-N-V2, CX532P-N-V2 and CX732Q-N-V2.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# loopback-pkt-drop
ipv6 use-link-local
Section titled “ipv6 use-link-local”[Command]
ipv6 use-link-local
[Purpose]
Enable the IPv6 link local address function of the interface.
[View]
Physical Interface Configuration View
[Notes]
Setting an IPv6 address will automatically enable this feature. Run command no ipv6 use-link-local to disable this feature.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# ipv6 use-link-local
Subinterface
Section titled “Subinterface”Subinterface Status View
Section titled “Subinterface Status View”Table 6 Subinterface Status View
Command | Purpose |
---|---|
show sub-interface [ethernet interface_name.subinterface-number] | Display information about the status of subinterfaces. |
show {ip|ipv6} interfaces | Display IP address configuration of subinterfaces. |
show sub-interface [ethernet interface_name.subinterface-number]
Section titled “show sub-interface [ethernet interface_name.subinterface-number]”[Command]
show sub-interface [ethernet interface_name.subinterface-number]
[Purpose]
Display information about the status of subinterfaces.
[Parameters]
Parameter | Description |
---|---|
interface_name | Parent interface name. (eg.0/1) |
subinterface-number | Subinterface number. |
[View]
Privileged User View
[Use Cases]
sonic# show sub-interface Sub port interface Speed MTU vlan Admin Type-------------------- ------- ----- ------ ------- -------------------- 0/0.2 25G 9100 2 up 802.1q-encapsulation
show {ip|ipv6} interfaces
Section titled “show {ip|ipv6} interfaces”[Command]
show {ip|ipv6} interfaces
[Purpose]
Display IP address configuration of subinterfaces.
[View]
Privileged User View
[Use Cases]
sonic# show ip interfacesInterface Master IPv4 address/mask Admin/Oper BGP Neighbor Neighbor IP----------- -------- ------------------- ------------ -------------- -------------0/0.2 2.0.0.1/24 up/down N/A N/A0/48 199.0.3.1/24 up/up N/A N/A0/52 199.0.7.1/24 up/up N/A N/Aloopback0 10.1.0.34/32 up/up N/A N/Amgmt 10.250.0.138/24 up/up N/A N/A
Subinterface Config
Section titled “Subinterface Config”Table 7 Subinterface Config
Command | Purpose |
---|---|
interface {ethernet|link-aggregation} interface_name.subinterface-number | Create a subinterface. |
mtu mtu | Configure the MTU value on a subinterface. |
shutdown | Bring the subinterface down administratively. |
ip address {A.B.C.D/M|A::B/M} [secondary] | Configure IP address for the subinterface. |
mac_address HH:HH:HH:HH:HH:HH | Specify a MAC address to the subinterface. |
interface {ethernet|link-aggregation} interface_name.subinterface-number
Section titled “interface {ethernet|link-aggregation} interface_name.subinterface-number”[Command]
interface {ethernet|link-aggregation} interface_name.subinterface-number
[Purpose]
Create a subinterface.
[Parameters]
Parameter | Description |
---|---|
interface_name | Parent interface name. (eg.0/1) |
subinterface-number | Subinterface number. |
[View]
Global Configuration View
[Notes]
Run command no interface {ethernet|link-aggregation} interface_name.subinterface-number to delete the subinterface.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1.1sonic(config-if-0/1.1)# show this!interface ethernet 0/1.1sonic(config)# no interface ethernet 0/1.1
mtu mtu
Section titled “mtu mtu”[Command]
mtu mtu
[Purpose]
Configure the MTU value on a subinterface.
[Parameters]
Parameter | Description |
---|---|
mtu | Maximum Transmission Unit, the range is from 1312 to 9216. The default is 9216 Bytes. |
[View]
Subinterface Configuration View
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1.1sonic(config-if-0/1.1)# mtu 2000sonic(config-if-0/1.1)# show this!interface ethernet 0/1.1 mtu 2000
shutdown
Section titled “shutdown”[Command]
shutdown
[Purpose]
Bring the subinterface down administratively.
[View]
Subinterface Configuration View
[Notes]
Run command no shutdown to bring the sub-interface up administratively.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/1.1sonic(config-if-0/1.1)# shutdownsonic(config-if-0/1.1)# show this!interface ethernet 0/1.1 shutdown
ip address {A.B.C.D/M|A::B/M} [secondary]
Section titled “ip address {A.B.C.D/M|A::B/M} [secondary]”[Command]
ip address {A.B.C.D/M|A::B/M} [secondary]
[Purpose]
Configure IP address for the subinterface.
[Parameters]
Parameter | Description |
---|---|
A.B.C.D/M | IPv4 address with prefix length. |
A::B/M | IPv6 address with prefix length. |
secondary | The default is Primary IP, specifying this option means configuring as Secondary IP, which requires that the Secondary IP and Primary IP be in the same network segment. |
[View]
Subinterface Configuration View
[Notes]
IPv4 address with subnet mask /32 is not allowed to be configured. Addresses with subnet mask /31 is allowed. In other subnet masks, addresses with the host portion all-zeros or all-ones are not allowed. IPv6 address with subnet mask /127 or /128 is not allowed to be configured. In other subnet masks, addresses with the host portion all-zeros are not allowed, but all-ones are allowed. Run command no ip address {A.B.C.D/M|A::B/M} [secondary]to delete IP address configuration of the subinterface.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2.2sonic(config-if-0/2.2)# ip address 3.3.3.6/24sonic(config-if-0/2.2)# show this!interface ethernet 0/2.2ip address 3.3.3.6/24
mac_address HH:HH:HH:HH:HH:HH
Section titled “mac_address HH:HH:HH:HH:HH:HH”[Command]
mac_address HH:HH:HH:HH:HH:HH
[Purpose]
Specify a MAC address to the subinterface.
[Parameters]
Parameter | Description |
---|---|
HH:HH:HH:HH:HH:HH | MAC address, not case sensitive. |
[View]
Subinterface Configuration View
[Notes]
The default is the MAC of the switch. Run command no mac_address to restore the MAC of the sub-interface to default.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/2.2sonic(config-if-0/2.2)# mac-address 18:17:25:37:67:afsonic(config-if-0/2.2)# show this!interface ethernet 0/2.2 mac-address 18:17:25:37:67:af
Loopback
Section titled “Loopback”Loopback View
Section titled “Loopback View”Table 8 Loopback View
Command | Purpose |
---|---|
show {ip|ipv6} interfaces | Display IP address configuration of loopback interfaces. |
show {ip|ipv6} interfaces
Section titled “show {ip|ipv6} interfaces”[Command]
show {ip|ipv6} interfaces
[Purpose]
Display IP address configuration of loopback interfaces.
[View]
Privileged User View
[Use Cases]
sonic# show ip interfacesInterface Master IPv4 address/mask Admin/Oper BGP Neighbor Neighbor IP----------- -------- ------------------- ------------ -------------- -------------0/48 199.0.3.1/24 up/up N/A N/A0/52 199.0.7.1/24 up/up N/A N/A0/72 10.72.0.1/24 up/up N/A N/Aloopback0 10.1.0.34/32 up/up N/A N/Amgmt 10.250.0.138/24 up/up N/A N/A
Loopback Config
Section titled “Loopback Config”Table 9 Loopback Config
Command | Purpose |
---|---|
interface loopback loopback-id | Enter Loopback Interface Configuration View. |
ip address {A.B.C.D/M|A::B/M} | Configure IP address for the loopback interface. |
interface loopback loopback-id
Section titled “interface loopback loopback-id”[Command]
interface loopback loopback-id
[Purpose]
Enter Loopback Interface Configuration View
[Parameters]
Parameter | Description |
---|---|
loopback-id | Loopback interface number, integer form, range from 0 to 999. |
[View]
Global Configuration View
[Notes]
Loopback0 has been created by default and cannot be deleted. Run command no interface loopback loopback-id to delete loopback interface.
[Use Cases]
sonic# configure terminalsonic(config)# interface loopback 1sonic(config-loif-1)# show this!interface loopback 1
ip address {A.B.C.D/M|A::B/M}
Section titled “ip address {A.B.C.D/M|A::B/M}”[Command]
ip address {A.B.C.D/M|A::B/M}
[Purpose]
Configure IP address for the loopback interface.
[Parameters]
Parameter | Description |
---|---|
A.B.C.D/M | IPv4 address with prefix length. |
A::B/M | IPv6 address with prefix length. |
[View]
Loopback Interface Configuration View
[Notes]
Run command no ip address {A.B.C.D/M|A::B/M} to delete IP address configuration of the loopback interface.
[Use Cases]
sonic# configure terminalsonic(config)# interface loopback 2sonic(config-loif-2)# ip address 3.3.3.6/24sonic(config-loif-2)# show this!interface loopback 2ip address 3.3.3.6/24
CRC Config
Section titled “CRC Config”Table 10 CRC Config
Command | Purpose |
---|---|
crc-check enable | Enable CRC error packets detection. |
crc-check threshold interval count | Set the threshold of CRC error detection. |
crc-check enable
Section titled “crc-check enable”[Command]
crc-check enable
[Purpose]
Enable CRC error packets detection.
[View]
Global Configuration View
[Notes]
Run command no crc-check enable to disable CRC error packets detection.
[Use Cases]
sonic(config)# crc-check enableCreated symlink /etc/systemd/system/sonic.target.wants/counterscheckmgrd.service/lib/systemd/system/counterscheckmgrd.service.sonic(config)# no crc-check enableRemoved /etc/systemd/system/sonic.target.wants/counterscheckmgrd.service.
crc-check threshold interval count
Section titled “crc-check threshold interval count”[Command]
crc-check threshold interval count
[Purpose]
Set the threshold of CRC error detection.
[Parameters]
Parameter | Description |
---|---|
interval | Set the interval in seconds, the range is 2~60, the default value is 10. |
count | Set the maximum count of CRC error packets in the range of [1,65535], the default value is 100. |
[View]
Global Configuration View
[Notes]
If the number of CRC error packets during the interval time exceeds the count number, the threshold is considered to be exceeded. When the received CRC error packets exceed the threshold, the system will automatically set the interface to errdown.
[Use Cases]
sonic(config)# crc-check threshold 10 100
Transceiver
Section titled “Transceiver”Transceiver View
Section titled “Transceiver View”Table 11 Transceiver View
Command | Purpose |
---|---|
show interface transceiver [ethernet interface_name] {eeprom [detail]|lpmode|presence} | Display optical module information of interfaces. |
show interface transceiver [ethernet interface_name] {eeprom [detail]|lpmode|presence}
Section titled “show interface transceiver [ethernet interface_name] {eeprom [detail]|lpmode|presence}”[Command]
show interface transceiver [ethernet interface_name] {eeprom [detail]|lpmode|presence}
[Purpose]
Display optical module information of interfaces.
[Parameters]
Parameter | Description |
---|---|
interface_name | Interface name (eg.0/1) |
[View]
Privileged User View
[Use Cases]
sonic# show interface transceiver ethernet 0/0 eeprom detail0/0 : SFP EEPROM detected Connector: MPOx12 Encoding: NRZ Extended Identifier: Power Class 4(3.5W max), CDR present in Rx Tx Extended RateSelect Compliance: Unknown Identifier: QSFP28 or later Length Cable Assembly(m): 50 Nominal Bit Rate(100Mbs): 255 Specification compliance: Vendor Date Code(YYYY-MM-DD Lot): 2022-07-08 Vendor Name: Teraspek Vendor OUI: 00-00-00 Vendor PN: TSQ885S101T1 Vendor Rev: 00 Vendor SN: 22070073 ChannelMonitorValues: RX1Power: 0.8422dBm RX2Power: 0.6971dBm RX3Power: 1.6414dBm RX4Power: 1.1458dBm TX1Bias: 6.0740mA TX2Bias: 6.2960mA TX3Bias: 5.9220mA TX4Bias: 6.5100mA ChannelThresholdValues: RxPowerHighAlarm : 4.4000dBm RxPowerHighWarning: 3.4001dBm RxPowerLowAlarm : -13.2975dBm RxPowerLowWarning : -10.3012dBm TxBiasHighAlarm : 10.0000mA TxBiasHighWarning : 8.5000mA TxBiasLowAlarm : 2.0000mA TxBiasLowWarning : 3.0000mA ModuleMonitorValues: Temperature: 32.9570C Vcc: 3.2961Volts ModuleThresholdValues: TempHighAlarm : 75.0000C TempHighWarning: 70.0000C TempLowAlarm : -5.0000C TempLowWarning : 0.0000C VccHighAlarm : 3.6300Volts VccHighWarning : 3.4650Volts VccLowAlarm : 2.9700Volts VccLowWarning : 3.1350Volts
Transceiver Config
Section titled “Transceiver Config”Table 12 Transceiver Config
Command | Purpose |
---|---|
cmis enable | Enable CMIS management. |
lpmode on | Enable low power consumption of the interface. |
transceiver frequency frequency | Configure the frequency of the optical module. |
transceiver transmitter signal-power power | Configure the signal transmission power of the optical module. |
cmis enable
Section titled “cmis enable”[Command]
cmis enable
[Purpose]
Enable CMIS management.
[View]
Global Configuration View
[Notes]
This command is designed for optical modules that support CMIS protocol to improve the stability of interface signal. By importing a JSON file, customizing and modifying the Signal Integrity configuration of the CMIS optical module, then enable CMIS management after restarting the device. After enabling this function for about 5 minutes, the SI information of the configured CMIS optical module can be read normally. Run command no cmis enable to disable CMIS management. Executing enable and disable commands will cause down/up of optical modules that support CMIS protocol but will not affect optical modules that do not support CMIS protocol.
[Use Cases]
Step 1: show the information of the optical module, find the Vendor Name and Vendor PN information.
spine# show interface transceiver ethernet 0/128 eeprom detail0/128 : SFP EEPROM detected Active App Selection Host Lane 1: 1 Active App Selection Host Lane 2: 1 Active App Selection Host Lane 3: 1 Active App Selection Host Lane 4: 1 Active App Selection Host Lane 5: 1 Active App Selection Host Lane 6: 1 Active App Selection Host Lane 7: 1 Active App Selection Host Lane 8: 1 Application Advertisement: 400GAUI-8 C2M (Annex 120E) - Host Assign (0x1) - Active Cable assembly with BER < 2.6x10^-4 - Media Assign (0x1) CMIS Revision: 4.0 Connector: No separable connector Encoding: N/A Extended Identifier: Power Class 4 (8.0W Max) Extended RateSelect Compliance: N/A Hardware Revision: 1.0 Host Electrical Interface: 400GAUI-8 C2M (Annex 120E) Host Lane Assignment Options: 1 Host Lane Count: 8 Identifier: QSFP-DD Double Density 8X Pluggable Transceiver Length Cable Assembly(m): 3.0 Media Interface Code: Active Cable assembly with BER < 2.6x10^-4 Media Interface Technology: 850 nm VCSEL Media Lane Assignment Options: 1 Media Lane Count: 8 Nominal Bit Rate(100Mbs): 0 Specification compliance: active_cable_media_interface Supported Max Laser Frequency: N/A GHz Supported Max TX Power: 0.0 dBm Supported Min Laser Frequency: N/A GHz Supported Min TX Power: 0.0 dBm Vendor Date Code(YYYY-MM-DD Lot): 2023-08-19 Vendor Name: OEM Vendor OUI: 00-00-00 Vendor PN: QSFPDD-400G-AOC Vendor Rev: 10 Vendor SN: SN23080288 Active Firmware Version: N/A Inactive Firmware Version: N/A ChannelMonitorValues: RX1Power: 1.69dBm RX2Power: 1.686dBm RX3Power: 1.598dBm RX4Power: 1.59dBm RX5Power: 1.014dBm RX6Power: 1.257dBm RX7Power: 1.182dBm RX8Power: 1.239dBm TX1Bias: 7.474mA TX1Power: 0.678dBm TX2Bias: 7.466mA TX2Power: 0.612dBm TX3Bias: 7.46mA TX3Power: 0.66dBm TX4Bias: 7.44mA TX4Power: 0.662dBm TX5Bias: 7.48mA TX5Power: 0.658dBm TX6Bias: 7.472mA TX6Power: 0.591dBm TX7Bias: 7.456mA TX7Power: 0.64dBm TX8Bias: 7.45mA TX8Power: 0.642dBm ModuleMonitorValues: Temperature: 44.004C Vcc: 3.251Volts ChannelThresholdValues: RxPowerHighAlarm : 7.0dBm RxPowerHighWarning: 4.0dBm RxPowerLowAlarm : -10.0dBm RxPowerLowWarning : -7.001dBm TxBiasHighAlarm : 12.0mA TxBiasHighWarning : 10.0mA TxBiasLowAlarm : 2.0mA TxBiasLowWarning : 4.0mA TxPowerHighAlarm : 7.0dBm TxPowerHighWarning: 4.0dBm TxPowerLowAlarm : -9.5dBm TxPowerLowWarning : -6.501dBm ModuleThresholdValues: TempHighAlarm : 80.0C TempHighWarning: 70.0C TempLowAlarm : -10.0C TempLowWarning : 0.0C VccHighAlarm : 3.63Volts VccHighWarning : 3.465Volts VccLowAlarm : 2.97Volts VccLowWarning : 3.135Volts
Check the interface status and read the alias number of the interface
spine# show interface summary Interface Lanes Speed MTU FEC Alias Vlan Oper Admin Type Asym PFC--------------- ------------------------------- ------- ----- ----- ------- --------------- ------ ------- ----------------------------------------------- ---------- 0/0 217,218,219,220,221,222,223,224 400G 9216 rs QC1 trunk down up QSFP-DD Double Density 8X Pluggable Transceiver N/A 0/8 209,210,211,212 100G 9216 rs QC2 trunk down up N/A N/A 0/16 249,250,251,252 100G 9216 rs QC3 trunk down up N/A N/A 0/24 241,242,243,244 100G 9216 rs QC4 routed down up N/A N/A 0/32 233,234,235,236 100G 9216 rs QC5 routed down up N/A N/A 0/40 225,226,227,228,229,230,231,232 400G 9216 rs QC6 trunk down up QSFP-DD Double Density 8X Pluggable Transceiver N/A 0/48 201,202,203,204 100G 9216 rs QC7 lag48 up up QSFP28 or later N/A 0/56 193,194,195,196 100G 9216 rs QC8 lag56 up up QSFP28 or later N/A 0/64 185,186,187,188 100G 9216 rs QC9 lag64 up up QSFP28 or later N/A 0/72 177,178,179,180 100G 9216 rs QC10 lag72 up up QSFP28 or later N/A 0/80 169,170,171,172 100G 9216 rs QC11 routed up up QSFP28 or later N/A 0/88 161,162,163,164 100G 9216 rs QC12 routed up up QSFP28 or later N/A 0/96 153,154,155,156 100G 9216 rs QC13 routed up up QSFP28 or later N/A 0/104 145,146 100G 9216 rs QC14 routed down up N/A N/A 0/112 137,138,139,140 100G 9216 rs QC15 trunk down up N/A N/A 0/120 129,130,131,132 100G 9216 rs QC16 trunk down up N/A N/A 0/128 121,122,123,124,125,126,127,128 400G 9216 rs QC17 routed up up QSFP-DD Double Density 8X Pluggable Transceiver N/A 0/136 113,114,115,116,117,118,119,120 400G 9216 rs QC18 routed up up QSFP-DD Double Density 8X Pluggable Transceiver N/A 0/144 105,106,107,108,109,110,111,112 400G 9216 rs QC19 routed down up N/A N/A 0/152 97,98,99,100,101,102,103,104 400G 9216 rs QC20 routed down up N/A N/A 0/160 89,90,91,92 100G 9216 rs QC21 routed down up N/A N/A 0/168 81,82,83,84 100G 9216 rs QC22 routed up up QSFP28 or later N/A 0/176 65,66,67,68 100G 9216 rs QC23 routed down up N/A N/A 0/184 73,74,75,76,77,78,79,80 400G 9216 rs QC24 routed down up QSFP-DD Double Density 8X Pluggable Transceiver N/A 0/192 49,50,51,52,53,54,55,56 400G 9216 rs QC25 routed down up N/A N/A 0/200 57,58,59,60 100G 9216 rs QC26 routed down up N/A N/A 0/208 17,18,19,20 100G 9216 rs QC27 routed down up QSFP28 or later N/A 0/216 25,26,27,28 100G 9216 rs QC28 routed up up QSFP28 or later N/A 0/224 1,2,3,4 100G 9216 rs QC29 trunk down up N/A N/A 0/232 9,10,11,12 100G 9216 rs QC30 routed down up QSFP28 or later N/A 0/240 33,34,35,36 100G 9216 rs QC31 routed down up QSFP+ or later with CMIS N/A 0/248 41,42,43,44 100G 9216 rs QC32 routed down up N/A N/A 0/256 258 10G 9216 none X1 lag47 up up SFP/SFP+/SFP28 N/A 0/257 257 10G 9216 none X2 routed down up SFP/SFP+/SFP28 N/A
Find the corresponding I2C bus number based on the alias number and read the optical module parameter information based on the I2C bus number. The method of mapping the alias number to the i2c bus number varies depending on the device. For CX73Q-N devices, the alias number is mapped to the i2c bus number by adding 1, while for CX864E-N devices, the alias number is mapped to the i2c bus number by adding 5, The first 32 ports of the CX664D-N device correspond to i2c bus numbers 3, 4, 5, 6, 11, 12, 13, 14, 19, 20, 21, 22, 27, 28, 29, 30, 35, 36, 37, 38, 43, 44, 45, 46, 51, 52, 53, 54, 59, 60, 61, 62 in sequence. The i2c bus numbers corresponding to the last 32 ports are 10, 9, 8, 7, 18, 17, 16, 15, 26,25, 24, 23, 34, 33, 32, 31, 42, 41, 40, 39, 50, 49, 48, 47, 58, 57, 56, 55,66, 65, 64, and 63.
Step2: In bash mode, create a JSON file containing SI configuration based on information such as the optical module model, manufacturer, number and speed of lanes, and alias number of interfaces, where the manufacturer name needs to be capitalized. Taking interface 0/128 of CX732Q-N device as an example, according to the information read above, Vendor Name is OEM, Vendor PN is QSFPDD-400G-AOC, the number of lanes is 8, the speed of the optical module is 400G, and the speed of each lane is 100G. The alias number of the interface is 17, and the mapped i2c bus number is 18.
admin@sonic:~$ sudo cat optics_si_settings.json{ "GLOBAL_MEDIA_SETTINGS":{ "0-31":{ "50G_SPEED":{ "OEM-QSFPDD-400G-AOC":{ "OutputEqPreCursorTargetRx":{ "OutputEqPreCursorTargetRx1":0, "OutputEqPreCursorTargetRx2":0, "OutputEqPreCursorTargetRx3":0, "OutputEqPreCursorTargetRx4":0, "OutputEqPreCursorTargetRx5":0, "OutputEqPreCursorTargetRx6":0, "OutputEqPreCursorTargetRx7":0, "OutputEqPreCursorTargetRx8":0 }, "OutputEqPostCursorTargetRx":{ "OutputEqPostCursorTargetRx1":2, "OutputEqPostCursorTargetRx2":2, "OutputEqPostCursorTargetRx3":2, "OutputEqPostCursorTargetRx4":2, "OutputEqPostCursorTargetRx5":2, "OutputEqPostCursorTargetRx6":2, "OutputEqPostCursorTargetRx7":2, "OutputEqPostCursorTargetRx8":2 }, "OutputAmplitudeTargetRx":{ "OutputAmplitudeTargetRx1":1, "OutputAmplitudeTargetRx2":1, "OutputAmplitudeTargetRx3":1, "OutputAmplitudeTargetRx4":1, "OutputAmplitudeTargetRx5":1, "OutputAmplitudeTargetRx6":1, "OutputAmplitudeTargetRx7":1, "OutputAmplitudeTargetRx8":1 }, "AdaptiveInputEqEnableTx": { "AdaptiveInputEqEnableTx1": 0, "AdaptiveInputEqEnableTx2": 0, "AdaptiveInputEqEnableTx3": 0, "AdaptiveInputEqEnableTx4": 0, "AdaptiveInputEqEnableTx5": 0, "AdaptiveInputEqEnableTx6": 0, "AdaptiveInputEqEnableTx7": 0, "AdaptiveInputEqEnableTx8": 0 }, "AdaptiveInputEqRecalledTx": { "AdaptiveInputEqRecalledTx1": 1, "AdaptiveInputEqRecalledTx2": 1, "AdaptiveInputEqRecalledTx3": 1, "AdaptiveInputEqRecalledTx4": 1, "AdaptiveInputEqRecalledTx5": 1, "AdaptiveInputEqRecalledTx6": 1, "AdaptiveInputEqRecalledTx7": 1, "AdaptiveInputEqRecalledTx8": 1 }, "FixedInputEqTargetTx": { "FixedInputEqTargetTx1": 2, "FixedInputEqTargetTx2": 2, "FixedInputEqTargetTx3": 2, "FixedInputEqTargetTx4": 2, "FixedInputEqTargetTx5": 2, "FixedInputEqTargetTx6": 2, "FixedInputEqTargetTx7": 2, "FixedInputEqTargetTx8": 2 } } } } }, "PORT_MEDIA_SETTINGS":{ "17":{ "50G_SPEED":{ "OEM-QSFPDD-400G-AOC":{ "OutputEqPreCursorTargetRx":{ "OutputEqPreCursorTargetRx1":0, "OutputEqPreCursorTargetRx2":0, "OutputEqPreCursorTargetRx3":0, "OutputEqPreCursorTargetRx4":0, "OutputEqPreCursorTargetRx5":0, "OutputEqPreCursorTargetRx6":0, "OutputEqPreCursorTargetRx7":0, "OutputEqPreCursorTargetRx8":0 }, "OutputEqPostCursorTargetRx":{ "OutputEqPostCursorTargetRx1":2, "OutputEqPostCursorTargetRx2":2, "OutputEqPostCursorTargetRx3":2, "OutputEqPostCursorTargetRx4":2, "OutputEqPostCursorTargetRx5":2, "OutputEqPostCursorTargetRx6":2, "OutputEqPostCursorTargetRx7":2, "OutputEqPostCursorTargetRx8":2 }, "OutputAmplitudeTargetRx":{ "OutputAmplitudeTargetRx1":1, "OutputAmplitudeTargetRx2":1, "OutputAmplitudeTargetRx3":1, "OutputAmplitudeTargetRx4":1, "OutputAmplitudeTargetRx5":1, "OutputAmplitudeTargetRx6":1, "OutputAmplitudeTargetRx7":1, "OutputAmplitudeTargetRx8":1 }, "AdaptiveInputEqEnableTx": { "AdaptiveInputEqEnableTx1": 0, "AdaptiveInputEqEnableTx2": 0, "AdaptiveInputEqEnableTx3": 0, "AdaptiveInputEqEnableTx4": 0, "AdaptiveInputEqEnableTx5": 0, "AdaptiveInputEqEnableTx6": 0, "AdaptiveInputEqEnableTx7": 0, "AdaptiveInputEqEnableTx8": 0 }, "AdaptiveInputEqRecalledTx": { "AdaptiveInputEqRecalledTx1": 1, "AdaptiveInputEqRecalledTx2": 1, "AdaptiveInputEqRecalledTx3": 1, "AdaptiveInputEqRecalledTx4": 1, "AdaptiveInputEqRecalledTx5": 1, "AdaptiveInputEqRecalledTx6": 1, "AdaptiveInputEqRecalledTx7": 1, "AdaptiveInputEqRecalledTx8": 1 }, "FixedInputEqTargetTx": { "FixedInputEqTargetTx1": 2, "FixedInputEqTargetTx2": 2, "FixedInputEqTargetTx3": 2, "FixedInputEqTargetTx4": 2, "FixedInputEqTargetTx5": 2, "FixedInputEqTargetTx6": 2, "FixedInputEqTargetTx7": 2, "FixedInputEqTargetTx8": 2 } } } } }}
Step 3: Place the JSON file in the specified directory and restart the device.
admin@sonic:~$ sudo mv optics_si_settings.json /usr/share/sonic/device/x86_64-asterfusion_cx732q_n-r0/CX732Q-N_TL07E02/admin@sonic:~$ sudo /etc/sku_setup x86_64-asterfusion_cx732q_n-r0admin@sonic:~$ sudo config reload -y
Step 4: After the device returns to normal, enable CMIS management and wait for about 5 minutes for the configuration information to be updated to the optical module data.
sonic# configuresonic(config)# cmis enableStep 5: The SI information of the optical module can be read through i2c to verify whether the configuration is effective. Each SI parameter supports modification and specific address values. Refer to the table below. First, confirm whether the bit corresponding to support is 1. If it is 1, it indicates support for configuring this parameter. Continue to check whether the value on the address of the corresponding field is consistent with the value in the configuration file. If it is 0, it indicates that this parameter is not supported for configuration. When setting parameter values, they cannot exceed the value of the address corresponding to Max.
Table 13 Optical module SI parameter address table
Filed | Description | Page | Address |
---|---|---|---|
active_apsel_hostlane | Host Channel Application Selection | 11h | 0xD5[7:4]-0xCE[7:4] |
OutputEqPreCursorTargetRx(support) | - | 01h | 0xA2[3] |
OutputEqPreCursorTargetRx(Max) | - | 01h | 0x9A[3:0] |
OutputEqPreCursorTargetRx | - | 10h | 0xA5[7:0]-0xA2[7:0]( Every four bits correspond to one lane) |
OutputEqPostCursorTargetRx(support) | - | 01h | 0xA2[4] |
OutputEqPostCursorTargetRx(Max) | - | 01h | 0x9A[7:4] |
OutputEqPostCursorTargetRx | - | 10h | 0xA9[7:0]-0xA6[7:0]( Every four bits correspond to one lane) |
OutputAmplitudeTargetRx(support) | - | 01h | 0xA2[2] |
OutputAmplitudeTargetRx(Max) | - | 01h | 0x99[7:4] |
OutputAmplitudeTargetRx | - | 10h | 0xAD[7:0]-0xAA[7:0]( Every four bits correspond to one lane) |
AdaptiveInputEqEnableTx(support) | - | 01h | 0xA1[3] |
AdaptiveInputEqEnableTx | - | 10h | 0x99[7:0]( Each bit corresponds to a lane)(only 0 or 1) |
AdaptiveInputEqRecalledTx(support) | - | 01h | 0xA1[5],0xA1[6]( One of them is 1, which means support) |
AdaptiveInputEqRecalledTx | - | 10h | 0x9B[7:0]-0x9A[7:0]( Every two bits correspond to a lane) |
FixedInputEqTargetTx(support) | - | 01h | 0xA1[2] |
FixedInputEqTargetTx | - | 10h | 0x9F[7:0]-0x9C[7:0]( Every four bits correspond to one lane) |
Read the data on page 1 of i2c and determine whether the current module supports configuring this parameter based on the supported addresses of the fields in the table above. Taking the reading of the OutputEqPreCursorTarget Rx parameter as an example, according to the table above, the support bit for the parameter OutputEqPreCursorTarget Rx is located on page 1 of the i2c data, at 0xA2 [3].
admin@spine:~$ sudo i2cset -f -y 18 0x50 0x7f 0x1admin@spine:~$ sudo i2cdump -f -y 18 0x50No size specified (using byte-data access) 0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef00: 18 40 00 06 ff 00 00 00 00 00 00 00 00 00 29 b0 ?@.?..........)?10: 7e fe 00 00 00 00 00 00 00 00 20 00 00 00 00 00 ~?........ .....20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................50: 00 00 00 00 00 04 11 03 88 01 ff 00 00 00 00 00 .....?????......60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01 ...............?80: 00 00 01 00 00 00 00 00 00 00 42 68 07 d0 24 f0 ..?.......Bh??$?90: 55 20 46 00 00 00 9d 78 00 42 00 2a 02 07 06 03 U F...?x.B.\*????a0: 07 09 0d 00 00 00 80 57 55 00 00 00 00 00 00 00 ???...?WU.......b0: 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ?...............c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2e ................
After reading the first page of data, the value of A2 is 09, the corresponding binary is 0000 1001, and the value of 0xA2 [3] is 1, indicating that this parameter supports configuration. If setting parameter values is supported, read the data on page 10 of i2c, determine the actual effective value of the parameters, and compare it with the configuration values in the JSON file. According to the table above, the address bits of this parameter value are in the range of 0xA5 [7:0] -0xA2 [7:0], and every four bits correspond to the value of a lane.
admin@spine:~$ sudo i2cset -f -y 18 0x50 0x7f 0x10admin@spine:~$ sudo i2cdump -f -y 18 0x50No size specified (using byte-data access)` `0 1 2 3 4 5 6 7 8 9 a b c d e f 0123456789abcdef00: 18 40 00 06 ff 00 00 00 00 00 00 00 00 00 2b b7 ?@.?..........+?10: 7f 12 00 00 00 00 00 00 00 00 20 00 00 00 00 00 ??........ .....20: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................30: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................40: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................50: 00 00 00 00 00 04 11 03 88 01 ff 00 00 00 00 00 .....?????......60: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 10 ...............?80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................90: 00 11 11 11 11 11 11 11 11 00 00 00 33 33 33 33 .????????...3333a0: ff ff 00 00 00 00 00 00 00 00 11 11 11 11 00 00 ..........????..b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................c0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................
Reading the data on page 10, the values from 0xA2 to 0xA5 are all 00, corresponding to binary values of 0000 0000 0000 0000 0000 0000 0000. Each four bits corresponds to a lane value, and all lane values are 0, consistent with the configuration in the JSON file. Continue reading the OutputEqPostCursorTarget Rx parameter value, with a support bit of 0xA2 [4]. Based on the data read above, A2 is 09 and 0xA2 [4] is 0, indicating that this parameter does not support modification.
lpmode on
Section titled “lpmode on”[Command]
lpmode on
[Purpose]
Enable low power consumption of the interface.
[View]
Physical Interface Configuration View
[Notes]
This feature is turned off by default. Run command lpmode off to disable low power mode.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# lpmode on
transceiver frequency frequency
Section titled “transceiver frequency frequency”[Command]
transceiver frequency frequency
[Purpose]
Configure the frequency of the optical module.
[Parameters]
Parameter | Description |
---|---|
frequency | Laser frequency, in GHz, with a value range of 1-4294967295. |
[View]
Physical Interface Configuration View
[Notes]
Run command no transceiver frequency to remove the configured operating frequency of the optical module.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# transceiver frequency 100
transceiver transmitter signal-power power
Section titled “transceiver transmitter signal-power power”[Command]
transceiver transmitter signal-power power
[Purpose]
Configure the signal transmission power of the optical module.
[Parameters]
Parameter | Description |
---|---|
power | Signal transmission power, in dBm, with a value range of -327.68-327.67. |
[View]
Physical Interface Configuration View
[Notes]
Run command no transceiver transmitter signal-power to remove the configured optical module emission power.
[Use Cases]
sonic# configure terminalsonic(config)# interface ethernet 0/0sonic(config-if-0/0)# transceiver transmitter signal-power 100
Asterfusion AI and data center SONiC switches as the links below