OSPF—BFD Multi-Hop Session
This section provides the steps for configuring BFD for OSPF multi-hop sessions.
Topology
Figure 2-166: Multi-hop OSPFv2 Topology
R1
R1#configure terminal | Enter the Configure mode. |
R1(config)#interface lo | Enter the Interface configuration mode for lo |
R1(config-if)#ip address 1.1.1.1/32 secondary | Assign IP Address |
R1(config)#interface eth1 | Enter the Interface configuration mode for eth1. |
R1(config-if)#ip address 10.1.1.1/24 | Assign IP Address |
R1(config-if)#exit | Exit the Interface configuration mode. |
R1(config)#interface eth2 | Enter the Interface configuration mode for eth1. |
R1(config-if)#ip address 30.1.1.1/24 | Assign IP Address |
R1(config-if)#exit | Exit the Interface configuration mode. |
R1(config)#router ospf 100 | Enter the Router mode for OSPF. |
R1(config-router)#ospf router-id 1.1.1.1 | OSPF router ID in IPv4 format |
R1(config-router)#bfd all-interfaces | Enable BFD for all neighbors. |
R1(config-router)#network 10.1.1.0/24 area 1 | Advertise network 20.1.1.0/24 in OSPF area 1. |
R1(config-router)#network 1.1.1.1/32 area 1 | Advertise loopback network 1.1.1.1/32 in OSPF area 1. |
R1(config-router)#network 30.1.1.0/24 area 0 | Advertise network 30.1.1.0/24 in OSPF area 0. |
R1(config-router)#area 1 virtual-link 3.3.3.3 fall-over bfd | Create a virtual link to R3 with BFD. |
R1(config-router)#commit | Commit the configuration on the node |
R2
R2#configure terminal | Enter the Configure mode |
R2(config)#interface eth1 | Enter the Interface configuration mode for eth1. |
R2(config-if)#ip address 10.1.1.2/24 | Assign IP Address |
R2(config-if)#exit | Exit the Interface configuration mode. |
R2(config)#interface eth2 | Enter the Interface configuration mode for eth2. |
R2(config-if)#ip address 20.1.1.1/24 | Assign IP Address |
R2(config-if)#exit | Exit the Interface configuration mode |
R2(config)#interface lo | Enter the Interface configuration mode for lo |
R2(config-if)#ip address 2.2.2.2/32 secondary | Assign IP Address |
R2(config-if)#exit | Exit the Interface configuration mode |
R2(config)#router ospf 100 | Enter the Router mode for OSPF. |
R2(config-router)#bfd all-interfaces | Enable BFD for all neighbors. |
R2(config-router)#ospf router-id 2.2.2.2 | OSPF router ID in IPv4 format |
R2(config-router)#network 10.1.1.0/24 area 1 | Advertise network 10.1.1.0/24 in OSPF area 1. |
R2(config-router)#network 20.1.1.0/24 area 1 | Advertise network 20.1.1.0/24 in OSPF area 1. |
R2(config-router)#network 2.2.2.2/32 area 1 | Advertise loopback network 2.2.2.2/32 in OSPF area 1. |
R2(config-router)#commit | Commit the configuration on the node |
R2(config-router)#exit | Exit the router mode. |
R3
R3#configure terminal | Enter the Configure mode. |
R3(config)#interface lo | Enter the Interface configuration mode for lo |
R3(config-if)#ip address 3.3.3.3/32 secondary | Assign IP Address |
R3(config-if)#exit | Exit the Interface configuration mode. |
R3(config)#interface eth2 | Enter the Interface configuration mode for eth2. |
R3(config-if)#ip address 20.1.1.2/24 | Assign IP Address. |
R3(config-if)#exit | Exit the Interface configuration mode. |
R3(config)#router ospf 100 | Enter the Router mode for OSPF. |
R3(config-router)#ospf router-id 3.3.3.3 | OSPF router ID in IPv4 format |
R3(config-router)#bfd all-interfaces | Enable BFD for all neighbors. |
R3(config-router)#network 20.1.1.0/24 area 1 | Advertise network 20.1.1.0/24 in OSPF area 1. |
R3(config-router)#network 3.3.3.3/32 area 1 | Advertise loopback network 3.3.3.3/32 in OSPF area 1. |
R3(config-router)#area 1 virtual-link 1.1.1.1 fall-over bfd | Create a virtual link to R1 with BFD. |
R3(config-router)#commit | Commit the configuration on the node |
Validation
R1#sh bfd session
BFD process for VRF: (DEFAULT VRF)
=====================================================================================
Sess-Idx Remote-Disc Lower-Layer Sess-Type Sess-State UP-Time Interface Down-Reason Remote-Addr
257 257 IPv4 Multi-Hop Up 00:00:54 NA NA 20.1.1.2/32
Number of Sessions: 1
R2#sh bfd session
BFD process for VRF: (DEFAULT VRF)
=====================================================================================
Sess-Idx Remote-Disc Lower-Layer Sess-Type Sess-State UP-Time Interface Down-Reason Remote-Addr
Number of Sessions: 0
R3#sh bfd session
BFD process for VRF: (DEFAULT VRF)
=====================================================================================
Sess-Idx Remote-Disc Lower-Layer Sess-Type Sess-State UP-Time Interface Down-Reason Remote-Addr
257 257 IPv4 Multi-Hop Up 00:01:46 NA NA 10.1.1.1/32
Number of Sessions: 1
R1#sh bfd session detail
BFD process for VRF: (DEFAULT VRF)
====================================================================================
Session Interface Index : 0 Session Index : 257
Lower Layer : IPv4 Version : 1
Session Type : Multihop Arbit Path Session State : Up
Local Discriminator : 257 Local Address : 10.1.1.1/32
Remote Discriminator : 257 Remote Address : 20.1.1.2/32
Local Port : 49152 Remote Port : 4784
Options :
Diagnostics : None
Timers in Milliseconds :
Min Tx: 250 Min Rx: 250 Multiplier: 3
Neg Tx: 250 Neg Rx: 250 Neg detect mult: 3
Min echo Tx: 1000 Min echo Rx: 1000 Neg echo intrvl: 0
Storage type : 2
Sess down time : 00:00:00
Sess Down Reason : NA
Bfd GTSM Disabled
Bfd Authentication Disabled
Counters values:
Pkt In : 00000000000000000606 Pkt Out : 00000000000000000605
Pkts Drop : 00000000000000000000 Auth Pkts Drop : 00000000000000000000
Echo Out : 00000000000000000000 IPv6 Echo Out : 00000000000000000000
IPv6 Pkt In : 00000000000000000000 IPv6 Pkt Out : 00000000000000000000
UP Count : 1 UPTIME : 00:02:13
Protocol Client Info:
OSPF-> Client ID: 4 Flags: 4
----------------------------------------------------------
Number of Sessions: 1
R2#sh bfd session detail
BFD process for VRF: (DEFAULT VRF)
====================================================================================
Number of Sessions: 0
R2#
R3#sh bfd session detail
BFD process for VRF: (DEFAULT VRF)
====================================================================================
Session Interface Index : 0 Session Index : 257
Lower Layer : IPv4 Version : 1
Session Type : Multihop Arbit Path Session State : Up
Local Discriminator : 257 Local Address : 20.1.1.2/32
Remote Discriminator : 257 Remote Address : 10.1.1.1/32
Local Port : 49152 Remote Port : 4784
Options :
Diagnostics : None
Timers in Milliseconds :
Min Tx: 250 Min Rx: 250 Multiplier: 3
Neg Tx: 250 Neg Rx: 250 Neg detect mult: 3
Min echo Tx: 1000 Min echo Rx: 1000 Neg echo intrvl: 0
Storage type : 2
Sess down time : 00:00:00
Sess Down Reason : NA
Bfd GTSM Disabled
Bfd Authentication Disabled
Counters values:
Pkt In : 00000000000000000529 Pkt Out : 00000000000000000530
Pkts Drop : 00000000000000000000 Auth Pkts Drop : 00000000000000000000
Echo Out : 00000000000000000000 IPv6 Echo Out : 00000000000000000000
IPv6 Pkt In : 00000000000000000000 IPv6 Pkt Out : 00000000000000000000
UP Count : 1 UPTIME : 00:01:56
Protocol Client Info:
OSPF-> Client ID: 4 Flags: 4
----------------------------------------------------------
Number of Sessions: 1