Configuring BFD for OSPF in a Specified Process

Configuring BFD for OSPF in a specified process helps the system to rapidly detect the link status and speeds up OSPF convergence in the case of a link failure.

Context

After BFD for OSPF is configured, when detecting a link fault, BFD rapidly notifies the routers on both ends of the link of the fault, triggering rapid OSPF convergence. When the OSPF neighbor relationship goes Down, the BFD session will be dynamically deleted.

Before configuring BFD for OSPF, enable BFD globally.

Perform the following steps on the routers between which a BFD session is to be created.

Procedure

  1. Run system-view

    The system view is displayed.

  2. Run bfd

    BFD is globally configured.

  3. Run quit

    Return to the system view.

  4. Run ospf [ process-id ]

    The OSPF view is displayed.

  5. Run bfd all-interfaces enable

    BFD for OSPF is configured. The default parameter values are used to create a BFD session.

    If all the interfaces in a certain process are configured with BFD and their neighbor relationships are in the Full state, OSPF creates BFD sessions with default parameter values on all the interfaces in the process.

  6. (Optional) Run bfd all-interfaces { min-rx-interval receive-interval | min-tx-interval transmit-interval | detect-multiplier multiplier-value | frr-binding } *

    BFD session parameters are modified.

    You can skip this step. The default interval at which BFD packets are transmitted and the default detection multiplier are recommended.

    The parameters are configured based on the network status and network reliability requirements. A short interval at which BFD packets are transmitted can be configured for a link that has a higher requirement for reliability. A long interval at which BFD packets are transmitted can be configured for a link that has a lower requirement for reliability.

    • Actual interval at which BFD packets are transmitted on the local router = Max { configured interval transmit-interval at which BFD packets are transmitted on the local router, configured interval receive-interval at which BFD packets are received on the peer router }
    • Actual interval at which BFD packets are received on the local router = Max { configured interval transmit-interval at which BFD packets are transmitted on the peer router, configured interval receive-interval at which BFD packets are received on the local router }
    • Actual time for detecting BFD packets = Actual interval at which BFD packets are received on the local router x Configured detection multiplier multiplier-value on the peer router

    For example:

    • On the local router, the configured interval at which BFD packets are transmitted is 200 ms; the configured interval at which BFD packets are received is 300 ms; the detection multiplier is 4.
    • On the peer router, the configured interval at which BFD packets are transmitted is 100 ms; the interval at which BFD packets are received is 600 ms; the detection multiplier is 5.

    Then:

    • On the local router, the actual interval at which BFD packets are transmitted is 600 ms calculated by using the formula max {200 ms, 600 ms}; the interval at which BFD packets are received is 300 ms calculated by using the formula max {100 ms, 300 ms}; the detection period is 1500 ms calculated by multiplying 300 ms by 5.
    • On the peer router, the actual interval at which BFD packets are transmitted is 300 ms calculated by using the formula max {100 ms, 300 ms}, the actual interval at which BFD packets are received is 600 ms calculated by using the formula max {200 ms, 600 ms}, and the detection period is 2400 ms calculated by multiplying 600 ms by 4.

  7. (Optional) Prevent an interface from dynamically creating a BFD session.

    After BFD for OSPF is configured, all interfaces on which neighbor relationships are Full in the OSPF process will create BFD sessions. To prevent specific interfaces from being enabled with BFD, disable these interfaces from dynamically creating BFD sessions.

    1. Run quit

      Return to the system view.

    2. Run interface interface-type interface-number

      The interface view is displayed.

    3. Run ospf bfd block

      An interface is prevented from dynamically creating a BFD session.

    4. Run quit

      Return to the system view.

    5. Run ospf [ process-id ]

      The OSPF view is displayed.

  8. (Optional) Run bfd all-interfaces incr-cost { cost | max-reachable }

    The OSPF process is enabled to adjust the cost based on BFD.

    The interface-specific BFD-associated cost value has a higher priority than the process-specific BFD-associated cost value.

  9. Run commit

    The configuration is committed.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
Next topic >