The types of interfaces supported by this series of switches include: Ethernet interface, Ethernet port for management (hereinafter referred to as management port), Console port (hereinafter referred to as serial port), and USB port. The types and number of interfaces supported by specific models can be found in the installation manual of the product. This section describes the configuration and commands related to the Ethernet port for management and the Ethernet interface.
2.1 Ethernet Interface for Management Configuration #
2.1.1 Introduction
The management port, usually with an RJ-45 connector, is used to connect to a back-end computer for debugging or to connect to a remote device for remote control. It is generally named eth0 or mgmt 0 in the device.
For Asterfusion Cloud products, the IP address is automatically obtained via the DHCP management port when AsterNOS is installed, and can be viewed via the linux command “/sbin/ifconfig eth0” or ” sudo ifconfig eth0“. Once the system has been installed automatically, you can log in to the device directly via SSH.
2.1.2 Management Port Configuration
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter management port configuration view | interface mgmt 0 | - |
Configure the management port IP address | ip address A.B.C.D/M gw A.B.C.D ipv6 address A::B/M gw A::B | 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. |
Exit management port configuration view | exit | - |
Save configuration | write | - |
2.1.3 Display and Maintenance
Operation | Commands | Description |
---|---|---|
View management port information | show interface mgmt | The IP of management port configured by the ifconfig or ip command is not displayed by this command. |
2.1.4 Specific Configuration Scenarios
2.1.4.1 First Login
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter management port configuration view | interface mgmt 0 | - |
Configure the management port IP address | ip address A.B.C.D/M gw A.B.C.D ipv6 address A::B/M gw A::B | 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. |
Exit management port configuration view | exit | - |
Save configuration | write | - |
2.1.4.2 Restore to Default Configuration
Operation | Commands | Description |
---|---|---|
Restore to default configuration. | delete startup-config [reserve-mgmt] | Run command reload to take effect. Option reserve-mgmt determine whether to reserve mgmt IP and gateway. |
Reload. | reload | - |
Enter global configuration view. | configure terminal | - |
Enter management port configuration view. | interface mgmt 0 | If you do not reserve mgmt configuration, you need to reconfigure mgmt IP through serial port. |
Configure management IP addresses. | ip address A.B.C.D/M gw A.B.C.D ipv6 address A::B/M gw A::B | 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. |
Exit management port configuration view. | exit | - |
Save configuration. | write | - |
2.2 Logical Interface Configuration #
2.2.1 Introduction
Logical interfaces are virtual interfaces that are capable of data exchange functions but do not physically exist and need to be created through configuration.
This section focuses on the several types of logical interfaces supported by the device, as shown in the following table.
2.2.2 Logical Interface Default Configuration
The default setting of the logical interfaces is shown in the table below.
Parameters | Default value |
---|---|
VLANIF interface | None |
LAGIF interface | None |
Ethernet Layer 3 sub-interface | None |
Loopback interface | Default configuration is Loopback0 interface, using address 10.1.0.1/32 |
2.2.3 Configuring the VLANIF Interface
Please see the VLAN configuration section.
2.2.4 Configuring the LAGIF Interface
Please see the LAG configuration section.
2.2.5 Configuring Ethernet Layer 3 Sub-Interfaces
Please see the Layer 3 Ethernet Interface Configuration section.
2.2.6 Configure the Loopback Interface
The device is shipped with a Loopback0 interface configured by default, which is a special and fixed Loopback interface. In addition to this, the user can configure multiple loopback ports, but only one IP address is supported for a single loopback port.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Loopback interface configuration view or create a Loopback interface | interface loopback lo-id | - |
Configure Loopback interface IP address | ip address {A.B.C.D/M|A::B/M} | - |
2.2.7 Configure VXLAN Interfaces
Please see the VXLAN configuration section.
2.3 Ethernet interface Configuration #
2.3.1 Introduction
Ethernet interfaces are generally used as service interfaces to undertake service transmissions and are sometimes referred to as ports.
2.3.2 Rules for numbering
2.3.2.1 Default Rules for numbering
The Ethernet interface numbering format for Asterfusion products is: X/Y.
- ‘X’ indicates the board number. There are no boards in the current series, so ‘X’ is specified as 0.
- ‘Y’ indicates the interface number, starting from 0 and increasing. It should be noted that the naming intervals vary for different rate interfaces. 25GE interfaces are numbered in increments of 1, e.g., 0/0, 0/1……, and so on; 100GE and 200GE interfaces are numbered in increments of 4, e.g., 0/0, 0/4, 0/8……, and so on; and 400GE interfaces are numbered in increments of are 8, such as 0/0, 0/8, 0/16……, and so on.
2.3.2.2 Alias Mode Rules for numbering
In addition to the default mode, the Alias attribute (interface alias) is defined, with a one-to-one relationship with the physical port, related to the interface speed with the naming convention is shown in the table below, where the numbering starts at 1.
Interface Speed | Markings | Interface Breakout |
---|---|---|
1G | G | - |
10G | X | - |
25G | Y | - |
40G | Q | - |
100G | C | C1_X1/C1_Y1 |
200G | D | D1_C1 |
400G | QC | QC1_C1 |
Example:
‘0/X1’ indicates the first 10G interface of the box switch.
‘C1_Y1’ indicates the first 25G interface of the first 100G interface after breakout.
2.3.3 Interface Default Setting
The default setting of the Ethernet interface is shown in the table below.
Parameters | Default value |
---|---|
Interface name mode | default |
Self-consultation | Open |
Interface FEC | rs |
Interface management status | Up |
Interface speed | 25G or 100G |
Interface description information | N/A |
Interface splitting | Unsplit |
Interface MAC learning function | Open |
Interface LLDP function | Open |
Port ID type in interface LLDP | ifname |
Interface MTU | 9216 bytes |
Interface Layer 2 and 3 operating mode | Layer 2 model |
Interface MAC address | Dynamically assigned by the system, or the same as the device MAC address |
ARP proxy for interface | Disable |
2.3.4 Interface Base Configuration
This section describes the basic configuration of Ethernet interfaces.
2.3.4.1 Configure the Administrative State of the Interface
The state of the Ethernet interface is divided into Admin and Oper, of which there are two physical states, Up and Down. The communication state may only be Up when the administrative state of the interface is Up; when the administrative state of the interface is Down, the communication state will also be Down. This command is used to switch the administrative state of an interface.
By default, the administrative status of the interface is Up and the user can turn the interface on or off according to needs.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view. | interface ethernet interface-name | - |
Startup the interface | no shutdown | - |
Shutdown the interface | shutdown | - |
NOTE:
Once a Loopback interface has been created, it will remain UP and cannot be shut down or started using the command.
2.3.4.2 Configure the Interface Speed
The series supports the following interface speeds: 10G, 25G, 40G and 100G. The CX3 series provides 48 10G/25G interfaces and 8 100G/40G interfaces (25G and 100G by default); the CX5 series provides 32 100G/40G interfaces (100G by default). Users can configure the interface speed using the commands in the table below.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the interface speed | speed speed | speed in Mbit |
Example:
Modify interface Ethernet1 speed to 10G
sonic# configure terminal
sonic(config)# interface ethernet 0/1
sonic(config-if-0/1)# speed 10000
sonic(config-if-0/1)# show this
!
interface ethernet 0/1
speed 10000
sonic# show interface summary
Interface Lanes Speed MTU FEC Alias Vlan Oper Admi Type Asym PFC
…
0/1 114 10G 2000 none Y2 routed N/A up N/A N/A
…
2.3.4.3 Configure the Startup Delay of Interface
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the startup delay of interface | startup-delay time | ime: startup-delay time, range [1, 65535], in s |
Restore the startup delay of interface to the default setting | no startup-delay | - |
2.3.4.4 Configure Interface Description Information
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure interface description information | description description | There is only one description for an interface and multiple configurations will overwrite it. |
Delete interface description information | no description | - |
2.3.5 Configure Interface Self-Negotiation
In the network, if the devices at both ends of the link cannot negotiate the appropriate data transmission capacity, the two parties cannot communicate properly. The self-negotiation function provides a way for interconnected devices to exchange information so that the devices at both ends of the physical link automatically select the same operating parameters through interactive packets in order to achieve the maximum transmission capacity that both parties can support.
The self-negotiation includes the duplex mode and interface speed of the interfaces at both ends. Once the negotiation is passed, the devices on both ends of the link are locked to the same duplex mode and interface speed. In non-self-negotiating mode, the above parameters need to be configured manually.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Enable interface self-negotiation | autoneg | - |
Disable interface self-negotiation | no autoneg | - |
2.3.6 Configure the Interface FEC Mode
FEC (Forward Error Correction) is an error correction method that improves signal quality by attaching error correction information to the data packet at the transmitter side and using the error correction information at the receiver side to correct errors generated during transmission, but also causes some delay to the signal. The user can choose to turn this function off or on depending on the actual situation.
The FEC methods supported by the device are RS, FC and None.
NOTE: The FEC method must be the same at both ends of the link, otherwise the interface will not be Up.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the interface FEC mode | fec {rs|fc} | - |
Disable the FEC function | no fec | - |
2.3.7 Configure Interface Layer 2 and 3 Mode Switch
When using this command to switch between Layer 2 and Layer 3 modes of interface, only attribute configuration information (e.g. shutdown, description configuration) or configuration information that is supported by both Layer 2 and Layer 3 interfaces can be present under the interface for the mode switch function to take effect. There must not be any configuration that is not supported by the switched interface mode. If there are unsupported configurations on the interface, please clear all these configurations before executing the switchport or no switchport command.
For example, when an IP address is configured on interface 0/1, the IP needs to be removed before the switchport command can be executed.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Switche the operating mode of the interface to layer 3 | no switchport | - |
Switche the operating mode of the interface to layer 2 | switchport | - |
2.3.8 Configure Interface Isolation
Only CX308P-48Y-NF and CX532P-N-V2 devices support this feature.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Enable interface isolation | port-isolate enable group-name | group-name : isolation group name |
Disable interface isolation | no port-isolate enable | - |
2.3.9 Configure Interface Breakout
Interface breakout can split a high-speed port into multiple low-speed ports for use.
The 100G, 200G, and 400G optical interfaces supported by the device can be used as a separate interface or split into multiple independent interfaces for use. The 100G interface can be split into four 25G interfaces; 200G can be split into two 100G interfaces or four 50G interfaces; The 400G interface can be split into two 200G interfaces or four 100G interfaces.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Enable interface breakout. | breakout {4x25G[10G]|4x50G[10G]|2x200G[100G]|4x100G[50G]|2x100G[50G]} | - |
Restore interface breakout. | no breakout | - |
The support of different product models for the number and speed of interface breakout is shown in the table below.
Parameter | Description | Supported Devices |
---|---|---|
4x25G[10G] | Split one 100G port into four 25G ports | CX308P-48Y-N, CX308P-48Y-N-V2, CX532P-N, CX532P-N-V2,CX564P-N |
4x50G[10G] | Split one 200G port into four 50G ports | CX664D-N |
2x200G[100G] | Split one 400G port into two 200G ports | CX732Q-N |
4x100G[50G] | Split one 400G port into four 100G ports | CX732Q-N |
2x100G[50G] | Split one 200G port into two 50G ports | CX664D-N |
2.3.10 Layer 2 Interface Configuration
Layer 2 Ethernet interfaces work at the data link layer, handling Layer 2 protocols and enabling fast Layer 2 forwarding.
2.3.10.1 Configure the MAC learning switch for interface
Configure the interface’s MAC learning switch to require the operated interface to join the VLAN.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Enable MAC learning for the interface | mac-address learning | - |
Disable MAC learning for the interface | no mac-address learning | - |
2.3.11 Layer 3 Interface Configuration
Layer 3 Ethernet interface, also known as a RIF (Router Interface). The Layer 3 port works at the network layer and can be configured with IPv4/IPv6 addresses, handle Layer 3 protocols and provide route functions.
2.3.11.1 Configure the Interface IP Address
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the management port IP address | ip address A.B.C.D/M gw A.B.C.D ipv6 address A::B/M gw A::B | 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. |
Delete interface IP address | no ip address {A.B.C.D/M|A::B/M} | - |
2.3.11.2 Configure the Interface MTU
The network layer generally needs to limit the maximum length of each packet sent. When the network layer receives a copy of an IP packet to be sent, it determines which interface it should be forwarded to and queries the Maximum Transmission Unit (MTU) of that interface. The network layer compares the MTU value with the length of the IP packet to be sent. If the length of the IP packet is greater than the MTU value, then the packet is fragmented and the length of the fragmented packet is less than or equal to the MTU.
The size of the MTU determines the maximum number of bytes that can be sent at one time by the sender. A correctly configured MTU value is a prerequisite for proper and efficient communication between devices. When the packet size in the network is large but the MTU configuration is too small, it may cause excessive packet fragmentation, which may be discarded by the QoS queue and affect normal data transmission; if the MTU configuration is too large, it may exceed the maximum value that the receiving end can handle or exceed the maximum value that a device passing through on the sending path can handle, which may also cause packet fragmentation or even discard, adding to the burden of network transmission and affecting the normal transmission of data.
By default, the MTU of the interface is 9216 bytes.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the interface MTU | mtu mtu | MTU range: 1312 to 9216 |
2.3.11.3 Configure the MAC Address of the Interface
By default, the MAC address of the interface is dynamically assigned by the system or is the same as the MAC address of the device. This series supports users to reconfigure the MAC of physical interfaces, VLAN interfaces and link aggregate interfaces.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Configure the MAC address of the interface | mac-address HH:HH:HH:HH:HH:HH | MAC addresses are not case-sensitive |
Restore the MAC address of the interface to its default value | no mac-address | - |
2.3.11.4 Configure Layer 3 Sub-interfaces
A Layer 3 Ethernet interface supports the configuration of multiple sub-interfaces, which can be individually configured with IP, MTU and MAC address, or can be maintained independently to perform on/off operations.
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Create a sub-interface and enter the sub-interface view | interface ethernet interface-name.subinterface-number | - |
Configure the MAC address of the interface | ip address {A.B.C.D/M|A::B/M} | 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. |
Delete the IP address of the sub-interface | no ip address {A.B.C.D/M|A::B/M} | - |
Configure the MTU of the sub-interface | mtu mtu | - |
Shutdown sub-interface | shutdown | - |
Startup sub-interface | no shutdown | - |
Configure the MAC address of the sub-interface | mac-address HH:HH:HH:HH:HH:HH | MAC addresses are not case-sensitive |
Restore the MAC address of the atomic interface to its default value | no mac-address | - |
Delete sub-interface | no interface ethernet interface-name.subinterface-number | - |
2.3.11.5 Configure Interface Loop Traffic Drop
Operation | Commands | Description |
---|---|---|
Enter global configuration view | configure terminal | - |
Enter Ethernet interface view | interface ethernet interface-name | - |
Disable loop traffic drop | no loopback-pkt-drop | - |
Enable loop traffic drop | loopback-pkt-drop | - |
2.3.12 Display and Maintenance
2.3.12.1 Display Interface Configuration Information
Operation | Commands | Description |
---|---|---|
View interface description information | show interface description | - |
View interface status information | show interface summary | - |
View information about the interface | show interface ethernet interface-name | - |
View interface IPv4 address configuration | show ip interfaces | - |
2.3.12.2 Display Interface Status Information
Operation | Commands | Description |
---|---|---|
View interface status information | show interface summary | - |
View information about the interface | show interface ethernet interface-name | - |
View interface statistics | show counters interface [ethernet interface-name] | - |
View layer 3 port statistics | show counters rif {ethernet|vlan|link-aggregation} interface-name | - |
View LLDP neighbor information | show lldp neighbor {summary|interface interface-name} | - |
2.3.12.3 Clear Interface Statistics Count
Operation | Commands | Description |
---|---|---|
Clear interface statistics count information | clear counters {interface|rif} | - |
2.3.12.4 Display Information on Interface Optical Modules
Operation | Commands | Description |
---|---|---|
Display presence information of optical modules. | show interface transceiver [ethernet interface-name] presence | - |
Display detailed information of optical modules. | show interface transceiver [ethernet interface_name] eeprom [detail] | - |
Display low-power mode information of optical modules. | show interface transceiver [ethernet interface_name] lpmode | - |
2.3.12.5 Display Interface Isolation Configuration Information
Operation | Commands | Description |
---|---|---|
Display interface isolation configuration information | show isolate-group summary [ethernet interface-name] | - |
2.4 Console Interface #
2.4.1 Introduction
Console interface, or serial port, generally with RJ-45 connector, which is connected to the COM serial port of the configuration terminal and is used to build the field configuration environment. By default, AsterNOS 3.0 and above support serial console-based logins and SSH-based logins. The default username/password for login are admin/asteros. After logging into the switch via the serial port the user can configure the IP address of the management port (eth0) ,thereafter the user can log in to the device using SSH.
2.4.2 Example
For details on how to use it, see section1.1 .
Debian GNU/Linux 9 sonic ttyS0
sonic login: admin
Password:
Last login: Mon Jun 3 14:44:09 CST 2019 from 192.168.10.161 on pts/4
Linux sonic 4.9.0-8-amd64 #1 SMP Debian 4.9.110-3+deb9u6 (2015-12-19) x86_64
_ _ _ _ ___ ____
/ \ ___ | |_ ___ _ __ | \ | | / _ \ / ___|
/ _ \ / __|| __| / _ \| '__|| \| || | | |\___ \
/ ___ \ \__ \| |_ | __/| | | |\ || |_| | ___) |
/_/ \_\|___/ \__| \___||_| |_| \_| \___/ |____/
------- Asterfusion Network Operating System -------
Help: http://www.asterfusion.com/
admin@switch: