HCIP link aggregation, VRRP

link aggregation

        Link Aggregation --- Multiple physical interfaces can be bound into one logical interface , that is, N physical links can be aggregated into one logical link. The effect of increasing bandwidth can be achieved without upgrading the hardware

We call logical links aggregated links, and ETH-TRUNK links         in Huawei equipment (this technology is designed for Ethernet technology). We call each physical link a member link ; we call the aggregated interface an aggregated interface , which is called an ETH-TRUNK interface in Huawei equipment , and the previous physical interface is called a member interface

Link Aggregation Technology Requirements

  1. All physical interfaces of the channel should have the same transmission rate, duplex mode, and the same type ( ACCESS or TRUNK ) including the allowed list and PVID of the interface

  2. The opposite end of the channel must be the same device .

configuration

1. Create an aggregation interface

[sw2]interface Eth-Trunk 0

[sw2-Eth-Trunk0]

2. Divide the physical interface into the aggregation interface

[sw2-Eth-Trunk0]trunkport GigabitEthernet 0/0/1 0/0/2

[sw1]interface Ethernet 0/0/1 --- 也可以直接进入到物理接口,将其划入到对应的聚合接口中

[sw1-Ethernet0/0/1]eth-trunk 0

Note: In order to ensure that the aggregated interface state machine configurations are the same, Huawei devices impose the following restrictions

        1. Before aggregation, all interfaces cannot perform any configuration operations

        2. After aggregation, all operations are performed on the aggregated interface , not on the physical interface.

        The aggregated links of Huawei devices use flow-based load balancing by default . ---Huawei devices distinguish different data flows by source IP and destination IP by default

[sw2-Eth-Trunk1]load-balance ? --- 可以修改数据流的判断方式

dst-ip According to destination IP hash arithmetic --- 目标IP

dst-mac According to destination MAC hash arithmetic --- MAC

src-dst-ip According to source/destination IP hash arithmetic --- 源IP和目标IP

src-dst-mac According to source/destination MAC hash arithmetic --- 源IP和MAC地址

src-ip According to source IP hash arithmetic --- 源IP

src-mac According to source MAC hash arithmetic --- 源MAC
[r1-Eth-Trunk0]undo portswitch ---- 将二层接口改为三层接口

VRRP

        VRRP --- Virtual Router Redundancy Protocol

Version

        VRRP V2 ---- IPV4 --- Huawei uses VRRP V2 by default

        VRRP V3 --- IPV6

a group concept

        In VRRP, put all the routers that need to work together ( not necessarily only two devices, but also multiple devices ) into the same VRRP group. In order to distinguish different VRRP groups, we need to design a VRID for each group --- 8-bit binary composition --- a VRRP group needs a virtual gateway, and this gateway needs to be configured with a virtual IP address --- 1, must It has to be specified manually . 2. It must be configured in the same network segment as the IP address of the physical gateway interface . --- And a virtual MAC address will be automatically generated. ---- 0000 - 5e00 - 01XX --- The last 8 binary bits use the group's VRID to identify

VRRP working process

        If the gateway interface is configured to activate VRRP, all gateway interfaces will send VRRP data packets for the election of the master-standby relationship . After the election, only the master will periodically send VRRP Listening, if the VRRP data packet sent by the master is not received within 3.6s, it will be determined that the master is invalid, and the election will be re-run.

        The master is elected --- first compare the priority , 8-bit binary structure, the value range is 1 - 255, the default value is 100; the one with the higher priority as the master , and the rest of the devices are backup. If the priorities are the same, compare the IP addresses of the interfaces, and the one with the higher IP address prevails.

        3.6s --- 3 X cycle time + offset time (256 - priority) / 256

configuration

[r2-GigabitEthernet0/0/0]vrrp vrid 10 virtual-ip 192.168.1.254 --- 接口激活VRRP

Notice:

        The gateway devices that need to work together need to be placed in the same VRRP group , and the VRID must be configured the same. In Huawei devices, the virtual IP can use the IP address of the physical interface. The effect is that the interface device is directly identified as the master, and the priority is set to 255.

[r3-GigabitEthernet0/0/0]display vrrp --- 查看VRRP的配置信息

        Preempt : YES ---- VRRP protocol is preemptive mode enabled by default, but only valid for the wired level

[r3-GigabitEthernet0/0/0]vrrp vrid 10 priority 110 --- 修改优先级

[r3-GigabitEthernet0/0/0]vrrp vrid 10 track interface GigabitEthernet 0/0/1 reduced 50 --- 上行链路追踪。将优先级减少50

        Uplink Tracking --- If the tracked interface fails, the corresponding action will be performed . The current action is to reduce the priority by 50. (If no action is followed, the default priority will be reduced by 10)

おすすめ

転載: blog.csdn.net/qq_57289939/article/details/130325800