Track Object
The output shows that when BFD detects that Router A fails, it notifies VRRP through the Track module to
change the status of Router B to master without waiting for a period three times the advertisement interval.
This ensures that a backup can quickly preempt as the master.
Configuring BFD for the VRRP master to monitor the uplink
Network requirements
As shown in
•
192.168.0.10.
The default gateway of the hosts in the LAN is 192.168.0.10.
•
When Router A works correctly, hosts in the LAN access the external network through Router A.
•
When Router A detects that the uplink is down through BFD, it decreases its priority so that Router
B can preempt as the master, ensuring that the hosts in the LAN can access the external network
through Router B.
Figure 18 Network diagram
Master
uplink
device
GE1/0
1.1.1.2/24
GE1/0
1.1.1.1/24
Router A
Master
192.168.0.101/24
Configuration procedure
1.
Configure BFD on Router A:
# Configure the source address of BFD echo packets as 10.10.10.10.
<RouterA> system-view
[RouterA] bfd echo-source-ip 10.10.10.10
2.
Create the track entry to associate with the BFD session on Router A:
# Create track entry 1 for the BFD session on Router A to check whether the uplink device with the
IP address 1.1.1.2 is reachable.
: 1
Figure
18, Router A and Router B belong to VRRP group 1, whose virtual IP address is
Internet
Uplink
Virtual Router
Virtual IP address:
192.168.0.10
GE2/0
State : Negative
Backup
uplink
device
Uplink
Router B
Backup
GE2/0
192.168.0.102/24
L2 switch
BFD probe packets
VRRP packets
69
Switchover