vrrp vrid track ip route
Function
The vrrp vrid track ip route command associates a VRRP group with a route.
The undo vrrp vrid track ip route command disassociates a VRRP group from a route.
By default, a VRRP group is not associated with a route.
Format
vrrp vrid virtual-router-id track ip route ip-address { mask-address | mask-length } [ reduced value-reduced ]
undo vrrp vrid virtual-router-id track ip route [ ip-address { mask-address | mask-length } ]
Parameters
Parameter | Description | Value |
---|---|---|
vrid virtual-router-id | Specifies the VRID of a VRRP group. | The value is an integer that ranges from 1 to 255. |
ip-address | Specifies the IP address of the monitored route. | The value is in dotted decimal notation. |
mask-address | Specifies the mask of the IP address of the monitored route. | The value is in dotted decimal notation. |
mask-length | Specifies the mask length of the IP address of the monitored route. | The value is an integer that ranges from 0 to 32. |
reduced value-reduced | Specifies the value by which the master' priority decreases if the monitored route is withdrawn or becomes inactive. | The value is an integer that ranges from 1 to 255. The priority can decrease to 1. By default, the master' priority decreases by 10 if the associated route is withdrawn or becomes inactive. |
Usage Guidelines
Usage Scenario
To improve device reliability, two user gateways are configured to work in master/backup mode, and VRRP is enabled on these gateways to determine their Master and Backup states. Although a VRRP group has been configured, access devices may not detect route changes caused by the faulty uplink or network topology change. Consequently, data traffic is lost.
You can associate a VRRP group with a route for forwarding uplink traffic. When the route is withdrawn or becomes inactive, the master' priority is adjusted and an active/standby switchover is performed. When the status of the monitored route recovers, the original priority of the master in the VRRP group is restored.
Pre-configuration Tasks
A VRRP group and a routing protocol such as OSPF, BGP, or IS-IS have been configured.
Precautions
The VRRP group to be associated with a route cannot contain an IP address owner.
The master and backup in the VRRP group must work in preemption mode. It is recommended that the preemption delay be 0 on the backup and non-0 on the master.
Example
# Configure VRRP group 1 to monitor the route on 10.2.1.0, and set the value by which the master' priority decreases if the monitored route is withdrawn or becomes inactive to 20.
<AC6605> system-view [AC6605] interface vlanif 100 [AC6605-Vlanif100] vrrp vrid 1 virtual-ip 10.1.1.12 [AC6605-Vlanif100] vrrp vrid 1 track ip route 10.2.1.0 24 reduced 20