Vrrp principles of experimental work

  1. vrrp works
    VRRP:
    - Overview:
    vrrp, Virtual Router Redundancy Protocol, Virtual Router Redundancy Protocol.
    The main effect of the agreement is that after running across multiple real gateway device, to form a "virtual gateway",
    so that "redundancy" and load balancing for data forwarding between multiple gateways true.
    - Scene:
    When we order to improve the robustness of a network gateway, thereby deploying multiple gateway devices on the same network when,
    at this time, we need to run VRRP between multiple gateway devices, if only one gateway equipment is not required to run VRRP
    is.
    - Principle:
    VRRP after running on (Interface) devices, will form a virtual gateway device. By sending VRRP packets,
    comparison of the parameters to determine the role of different devices between a plurality of gateway devices true:
    Master - the master device; one and only one;
    Backup - backup device; there can be many;
    Once the role of master and backup devices is determined, only the master has been periodically send vrrp packets,
    if the backup device, within a certain period of time, has not received master sent from vrrp packets, it is considered
    the master device appears fault and the switching device role;
    transmission cycle: 1s
    maximum interval: 3s
    user terminal device when the gateway (virtual gateway) for transmitting data is actually processed by performing the master device.
    When the master faulty equipment, backup equipment will become a master, to continue to serve our customers;
    if the original master fails to recover, then the backup gateway device becomes a backup again;
  2. vrrp experimental environment
    test requirements:
    1.R1 and R2 is in the gateway 10 the VLAN;
    2.R1 and R2 VRRP enabled, the virtual gateway 10.250;
    3. To ensure R1-based gateway;
    4. determining VRRP packet mode transmission protocol number , the destination address
    5. determine the VRRP packet transmission period
    6 determines the default priority VRRP
  3. Configuration Procedure:
    1. Configure terminal device;
    2. configure network devices;
    # switching device arranged
    to create VLAN -> and an interface type belongs the VLAN
    # configure the routing device
    configured IP gateway
    3. Configuration VRRP
    enable VRRP, a virtual IP
    adjust the priority ensure R1-based gateway
    4. the verification and test
    * Check the state of each VRRP router
    • PC-1 Ping 10.250, determine the data forwarding path through packet capture
  4. Lab topology
    Vrrp principles of experimental work
  5. 实验过程
    配置交换机s1:
    [s1]vlan 10
    [s1]int g0/0/3
    [s1-GigabitEthernet0/0/3]port link-type acc
    [s1-GigabitEthernet0/0/3]port default vlan 10
    [s1-GigabitEthernet0/0/3]q
    [s1-port-group-1]group-member g0/0/1 g0/0/2
    [s1-port-group-1]port link-type access
    [s1-GigabitEthernet0/0/1]port link-type access
    [s1-GigabitEthernet0/0/2]port link-type access
    [s1-port-group-1]port default vlan 10
    [s1-GigabitEthernet0/0/1]port default vlan 10
    [s1-GigabitEthernet0/0/2]port default vlan 10
    [s1-port-group-1]

Router R1:
[R1-the GigabitEthernet0 / 0/0] the Add 192.168.10.251 IP gateway 24 // real VLAN10
[r1-GigabitEthernet0 / 0/0 ] vrrp vrid 1 virtual-ip 192.168.10.250 // vlan 10 as the primary gateway ;
[R1-the GigabitEthernet0 / 0/0] 200 is VRRP vrid priority. 1
Dis VRRP Brief:

Router R2
[R2] int G0 / 0/0
[the GigabitEthernet0-R2 / 0/0] the Add 192.168.10.252 IP gateway 24 // real VLAN10
[r2-GigabitEthernet0 / 0/0 ] vrrp vrid 1 virtual-ip 192.168.10.250 // vlan as a backup gateway 10;
[R2-the GigabitEthernet0 / 0/0]. 1 priority 100 VRRP vrid

Packet capture tool by testing: ping 192.168.10.250

Vrrp principles of experimental work
Vrrp principles of experimental work

理论知识:
[R2] display vrrp int g0/0/0
GigabitEthernet0/0/0 | Virtual Router 1
State : Backup //当前的状态为 backup,不再是master;
Virtual IP : 192.168.10.250
Master IP : 192.168.10.254
PriorityRun : 50 //该设备当前使用的优先级为:50
PriorityConfig : 150 //该设备手动配置的优先级为:150
MasterPriority : 100 //当前master的优先级为:100;
Preempt : YES Delay Time : 0 s
TimerRun : 1 s
TimerConfig : 1 s
Auth type : NONE
Virtual MAC : 0000-5e00-0101
Check TTL : YES
Config type : normal-vrrp
Backup-forward : disabled
Track IF : GigabitEthernet0/0/2 Priority reduced : 100 // 跟踪接口 gi0/0/2 ;
IF state : DOWN // 接口的状态变成了 down ;
VRRP常见的故障:多个master。
常见原因:
1.多个真实网关之间不通
2.两边配置的 VRID 不同
3.两边配置的 virtual-ip 不同
4.vrrp 认证不成功
拓展实验:
Vrrp principles of experimental work
路由器r3配置:
接口IP地址配置
路由配置:
[Huawei]ip route-static 192.168.10.0 255.255.255.0 192.168.20.1 preference 20
[Huawei]ip route-static 192.168.10.0 255.255.255.0 192.168.30.1
路径优先通过左边的方向
当down掉左边的接口:
Vrrp principles of experimental work
Vrrp principles of experimental work

两边路由器状态发生交换
Vrrp principles of experimental work
Vrrp principles of experimental work

Ping测试 右边路径正常通信
Vrrp principles of experimental work

1 简述VRRP抢占模式的作用
参考答案
优先级高的路由器down掉后,备份路由器成为主路由器。
当优先级高的路由器恢复后,如何重新成为主路由器?
华为默认开启抢占模式,使之重新获得转发权,恢复为主路由器。

Open ports, state recovery.
DESCRIPTION VRRP port 2 effects tracking
Answer
trace port is unavailable, priority is reduced, so that the backup router becomes the master router.
Port trace commands:
[R1-the GigabitEthernet0 / 0/0] Track int. 1 VRRP vrid G0 / 0/150. 1 reduced
see above backup operation priority router 50
acting Brief 3 floating route
reference answer
can be backed link usually a low priority to configure a static route as a backup route emergency triggered. In the primary route is valid, the floating route does not appear in the routing table.
Default priority 60, the larger the value, the lower the priority.
DESCRIPTION 4 VRRP Configuration Commands vrrp vrid 1 preempt-mode timer delay of action of 20
reference answer
after the high priority of the router is down, a backup router becomes the master router. When the high priority router recovers, (20 seconds) to restore the master router.

Guess you like

Origin blog.51cto.com/13415528/2425405