Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

bfd-liveness-detection (BGP)

Syntax

Hierarchy Level

Description

Configure bidirectional failure detection (BFD) timers and authentication for BGP.

For IBGP and multihop EBGP support, configure the bfd-liveness-detection statement at the global [edit bgp protocols] hierarchy level. You can also configure IBGP and multihop support for a routing instance or a logical system.

Options

holddown-interval milliseconds

(Optional) Configure an interval specifying how long a BFD session must remain up before a state change notification is sent.

When you configure the hold-down interval for the BFD protocol for EBGP, the BFD session is unaware of the BGP session during this time. In this case, if the BGP session goes down during the configured hold-down interval, BFD already assumes the BGP session is down and does not send a state change notification. The holddown-interval statement is supported only for EBGP peers at the [edit protocols bgp group group-name neighbor address] hierarchy level. If the BFD session goes down and then comes back up during the configured hold-down interval, the timer is restarted. You must configure the hold-down interval on both EBGP peers. If you configure the hold-down interval for a multihop EBGP session, you must also configure a local IP address by including the local-address statement at the [edit protocols bgp group group-name] hierarchy level.

  • Range: 0 through 255,000 milliseconds

  • Default: 0

minimum-interval milliseconds

(Required) Configure the minimum interval at which the local routing device transmits hello packets and then expects to receive a reply from a neighbor with which it has established a BFD session. Optionally, instead of using this statement, you can specify the minimum transmit and receive intervals separately using the minimum-interval (specified under the transmit-interval statement) and minimum-receive-interval statements.

  • Range: 1 through 255,000 milliseconds

minimum-receive-interval milliseconds

(Optional) Configure the minimum interval after which the local routing device must receive a reply from a neighbor with which it has established a BFD session. Optionally, instead of using this statement, you can configure the minimum receive interval using the minimum-interval statement.

  • Range: 1 through 255,000 milliseconds

multiplier number

(Optional) Configure the number of hello packets not received by a neighbor that causes the originating interface to be declared down.

  • Range: 1 through 255

  • Default: 3

no-adaptation

(Optional) Configure BFD sessions not to adapt to changing network conditions. We recommend that you do not disable BFD adaptation unless it is preferable to have BFD adaptation disabled in your network.

The BFD failure detection timers are adaptive and can be adjusted to be faster or slower. The lower the BFD failure detection timer value, the faster the failure detection and vice versa. For example, the timers can adapt to a higher value if the adjacency fails (that is, the timer detects failures more slowly). Or a neighbor can negotiate a higher value for a timer than the configured value. The timers adapt to a higher value when a BFD session flap occurs more than three times in a span of 15 seconds. A back-off algorithm increases the receive (Rx) interval by two if the local BFD instance is the reason for the session flap. The transmission (Tx) interval is increased by two if the remote BFD instance is the reason for the session flap. However, include the no-adaptation statement in the configuration if you do not want BFD sessions to adapt to changing network conditions.

You can use the clear bfd adaptation command to return BFD interval timers to their configured values. The clear bfd adaptation command does not affect traffic flow on the routing device.

  • Default: BFD sessions adapt to changing network conditions.

session-mode (automatic | multihop | single-hop)

(Optional) Configure BFD session mode to be single-hop or multihop. By default, BGP uses single-hop BFD sessions if the peer is directly connected to the router’s interface. BGP uses multihop BFD sessions if the peer is not directly connected to the router’s interface. If the peer session’s local-address option is configured, the directly connected check is based partly on the source address that would be used for BGP and BFD.

For backward compatibility, you can override the default behavior by configuring the single-hop or multihop option. Before Junos OS Release 11.1, the behavior was to assume that IBGP peer sessions were multihop.

  • Values: Specify one of these values:

    • automatic—Configure BGP to use single-hop BFD sessions if the peer is directly connected to the router’s interface, and multihop BFD sessions if the peer is not directly connected to the router’s interface.

    • multihop—Configure BGP to use multihop BFD sessions.

    • single-hop—Configure BGP to use single-hop BFD sessions.

  • Default: automatic

version (1 | automatic)

(Optional) Specify the BFD version.

  • Values: Specify one of the following:

    • 1—Configure BFD version 1.

    • automatic—Configure the device to automatically detect the BFD version.

  • Default: The device automatically detects the BFD version.

The remaining statements are explained separately. See CLI Explorer or click a linked statement in the Syntax section for details.

Required Privilege Level

routing—To view this statement in the configuration.

routing-control—To add this statement to the configuration.

Release Information

Statement introduced in Junos OS Release 8.1.

detection-time threshold and transmit-interval threshold options introduced in Junos OS Release 8.2.

Support for logical routers introduced in Junos OS Release 8.3.

Support for IBGP and multihop EBGP sessions introduced in Junos OS Release 8.3.

holddown-interval option introduced in Junos OS Release 8.5. You can configure this option only for EBGP peers at the [edit protocols bgp group group-name neighbor address] hierarchy level.

no-adaptation option introduced in Junos OS Release 9.0.

Support for BFD authentication introduced in Junos OS Release 9.6.

session-mode option introduced in Junos OS Release 11.1.

Support for BFD on IPv6 interfaces with BGP introduced in Junos OS Release 11.2.