To implement the redundancy function of network interface card (NIC) bonding, no special configuration is required on switches. To implement load balancing, port aggregation needs to be configured for switches. This topic uses the S5328C switch as an example to describe how to configure port aggregation for switches.
Enter system view, return user view with Ctrl+Z.
[S-switch]interface Eth-Trunk 1 //Create an Eth-Trunk. The trunk ID is 1, and the default manual load balancing mode is used.
[S-switch]interface GigabitEthernet 0/0/9
[S-switch-GigabitEthernet0/0/9]eth-trunk 1 //Add members to the Eth-Trunk.
Oct 1 2008 20:04:02 S-switch %%01TRUNK/4/TRUNKUP(l): Interface Eth-Trunk1 turns
into UP state.
[S-switch]interface GigabitEthernet 0/0/10
[S-switch]dis eth-trunk 1 //Check the configuration result.
Eth-Trunk1's state information is:
WorkingMode: NORMAL Hash arithmetic: According to MAC
Least Active-linknumber: 1 Max Bandwidth-affected-linknumber: 8
Operate status: up Number Of Up Port In Trunk: 2
PortName Status Weight
GigabitEthernet0/0/9 Up 1
GigabitEthernet0/0/10 Up 1
[S-switch]display trunkmembership eth-trunk 1
Trunk ID: 1
used status: VALID
Working Mode : Normal
Working State: Normal
Number Of Ports in Trunk = 2
Number Of UP Ports in Trunk = 2
operate status: up
Interface GigabitEthernet0/0/9, valid, selected, operate up, weight=1,
standby interface NULL
Interface GigabitEthernet0/0/10, valid, selected, operate up, weight=1,
standby interface NULL
<S-switch>save //Save the configuration.
The current configuration will be written to the device.
Are you sure to continue?[Y/N]y
Now saving the current configuration to the device.
Oct 1 2008 22:48:25 S-switch %%01CFM/4/SAVE(l): When deciding whether to save
configuration to the device, the user chose Y................................
Info: The current configuration was saved to the device successfully.
Ports 9 and 10 in the preceding commands indicate ports on the S5328C switch connected to network ports.
The preceding commands are configuration commands of Quidway S5300 series switches. To configure other models of switches, see related configuration manuals. In configuration manuals, you can type "aggregation" in the keyword to search for port aggregation commands.
When adding a port to the Eth-Trunk, ensure that the port is not configured (for example, the network cable type, duplex mode, or port rate is set). If "The port has configuration, please clear them first." is displayed, the port has been configured. In this case, run display this at this port to query its configurations, and then run undo to delete the configurations before adding the port to the Eth-Trunk.
Run display eth-trunk to query the load balancing mode of the Eth-Trunk. If the configuration is correct, the load balancing mode is displayed as NORMAL. Run display trunkmembership eth-trunk. If the configuration is correct, the Eth-Trunk working mode is displayed as Normal. In addition, the number of member ports and member ports in the Up state and member port information are displayed.
The working modes of bonded network ports are described as follows:
The active-backup, balance-tlb, and balance-alb modes do not require special configurations on switches.
The 802.3ad mode requires that switches be configured with Institute of Electrical and Electronics Engineers (IEEE) 802.3ad aggregation ports. Methods of configuring such ports vary according to switch types. For example, for Cisco 3550 series switches, you need to group the ports to be configured into an independent EtherChannel instance and then set the Link Aggregation Control Protocol (LACP) mode (for replacing the standard EtherChannel) for the EtherChannel instance.
The balance-rr, balance-xor, and broadcast modes require that corresponding switch ports be in the same group. Different switches name groups in different manners, such as, etherchannel, trunk group, or others. For these modes, each switch provides policy configuration options for data transmission to bonding devices. For example, exclusive OR (XOR) is performed on Media Access Control (MAC) addresses or IP addresses. Transmission policies at two ends may be different. For the three modes, a transmission policy is selected for an EtherChannel. All the three modes will interoperate with another EtherChannel.