Configuring BFD over OSPF

Topology for Configuring and Testing OSPF-BFD

Figure 1. OSPF-BFD Configuration and Testing Topology



The above shown figure depicts the components used in the topology. The description is as follows:

  • R1 and R2 represent the routers.
  • VLAN 1 represent the VLAN interfaces of the ISS routers.
  • Each ISS switch has a router ID. DUT stands for device under test.

For the list of the IPv4 and IPv6 addresses of the interfaces and hosts provided in the figure above, refer to the table as follows.

Table 1. IPv4 and IPv6 Addresses of Interfaces in the Routers and Hosts
Router Interface Slot IPv4 Address / Mask IPv6 Address/ Prefix Length
R1 VLAN 1 0/2 20.0.0.1 / 255.0.0.0 fe80::201:2ff:fe03:401 2001::2:0:0:1/64
R2 VLAN 1 0/2 20.0.0.1 / 255.0.0.0 fe80::202:2ff:fe03:401 2001::2:0:0:1/64

CLI Configurations

BFD can be used to monitor the IP path between OSPFv2 neighbors. For the Topology, refer to Figure OSPF-BFD Configuration and Testing Topology.

  1. Execute the following commands at R1.

    Type the following to configure OSPF router and BFD on OSPF router:

    • Enter the Global Configuration Mode.
    iS5comm# configure terminal
    • Enable OSPF globally in the switch and enter the Router Configuration mode.
    iS5comm(config)# router ospf
    • Configure the OOSPFSPF interfaces.
    iS5comm (config-router)# network 20.0.0.1 area 0.0.0.0
    iS5comm(config)# enable bfd
    • Enable BFD on all interfaces.
    iS5comm (config-router)# bfd all-interface
    • Exit from the Router Configuration mode.
    iS5comm(config-router)# end
  2. Execute the following commands at R2.

    Type the following to configure OSPF router and BFD on OSPF router:

    • Enter the Global Configuration Mode.
    iS5comm# configure terminal
    • Enable OSPF globally in the switch and enter the Router Configuration mode.
    iS5comm(config)# router ospf
    • Configure the OSPF interfaces.
    iS5comm (config-router)# network 20.0.0.2 area 0.0.0.0
    iS5comm(config)# enable bfd
    • Enable BFD on all interfaces.
    iS5comm (config-router)# bfd all-interface
    • Exit from the Router Configuration mode.
    iS5comm(config-router)# end
  3. View the BFD status.

    Type the following:

    iS5comm# show ip ospf neighbor
     Vrf  default 
    Neighbor-ID  Pri   State        DeadTime   Address     Interface Helper 
    -----------  ---   -----        --------   -------     ---------
    ---------   ------------ ---------  -----
    12.0.0.2     1     FULL/DR  33         20.0.0.2    vlan1     Not Helping 
    HelperAge    HelperER Bfd
    ---------------   --------------- --------
    0             	    None       enabled
  4. Shutdown interface gi 0/2 at R2.

    Type the following:

    iS5comm# configure terminal
    iS5comm(config)# int gi 0/2
    iS5comm(config)# shutdown
    iS5comm(config)# exit
  5. Verify if the BFD status becomes disabled and the BFD session goes down.

    Type the following:

    iS5comm# show ip ospf neighbor
     Vrf  default 
    Neighbor-ID  Pri   State        DeadTime   Address     Interface Helper 
    -----------  ---   -----        --------   -------     ---------
    ---------   ------------ ---------  -----
    12.0.0.2     1     FULL/DR  33         20.0.0.2    vlan1     Not Helping 
    HelperAge    HelperER Bfd
    ---------------   --------------- --------
    0             	    None       disabled

SNMP Configurations

  1. Enable BFD in OSPF.

    Type the following:

    snmp0 set {{fsMIOspfBfdStatus.0 1}}
    {1.3.6.1.4.1.2076.145.1.3.1.33.0 Integer32 enabled}
  2. Enable BFD in OSPF on all OSPF interfaces.

    Type the following:

    snmp0 set {{fsMIOspfBfdAllIfState.0 1}}
    {1.3.6.1.4.1.2076.145.1.3.1.34.0 Integer32 enabled}