The bidirectional forwarding detection (BFD) protocol is a simple hello mechanism that detects failures in a network. Hello packets are sent at a specified, regular interval. A neighbor failure is detected when the router stops receiving a reply after a specified interval. BFD works with a wide variety of network environments and topologies. The failure detection timers for BFD have shorter time limits than default failure detection mechanisms, providing faster detection. These timers are also adaptive and can be adjusted to be more or less aggressive. For example, the timers can adapt to a higher value if the adjacency fails, or a neighbor can negotiate a higher value for a timer than the one configured.
![]() |
Note: Beginning with JUNOS Release 8.3, BFD is also supported on IBGP and multihop EBGP sessions as well as on single-hop EBGP sessions. BFD does not support IPv6 interfaces with BGP. Beginning with JUNOS Release 9.1, BFD supports IPv6 interfaces in static routes only. |
To enable failure detection, include the bfd-liveness-detection statement:
-
bfd-liveness-detection {
-
- detection-time {
- threshold milliseconds;
- }
- holddown-interval milliseconds;
- minimum-interval milliseconds;
- minimum-receive-interval milliseconds;
- no-adaptation;
-
- transmit-interval {
- threshold milliseconds;
- minimum-interval milliseconds;
- }
- multiplier number;
- no-adaptation;
- version (1 | automatic);
- }
To specify the threshold for the adaptation of the detection time, include the detection-time threshold statement:
- detection-time {
- threshold milliseconds;
- }
When the BFD session detection time adapts to a value equal to or higher than the threshold, a single trap and a system log message are sent.
Beginning with JUNOS 8.5, you can configure an interval to specify how long the BFD session for an EBGP peer must remain up before a state change notification is sent. When you configure the hold-down interval for the BFD protocol for EBGP, the BGP session goes down if the BFD session goes down. If you do not configure the BFD hold-down interval, the BGP session remains up even if the BFD session goes down. To specify the hold-down interval, include the holddown-interval statement:
- holddown-interval milliseconds;
You can configure a value in the range from 0 through 255,000 and the default is 0. 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.
![]() |
Note: You must configure the hold-down interval on both EBGP peers. |
![]() |
Note: 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. For more information about configuring an EBGP multihop session, see Configuring an EBGP Multihop Session. For more information about configuring the local address, see Configuring the Local IP Address. |
To specify the minimum transmit and receive intervals for failure detection, include the minimum-interval statement:
- minimum-interval milliseconds;
This value represents the minimum interval at which the local router transmits hello packets as well as the minimum interval that the router expects to receive a reply from a neighbor with which it has established a BFD session. You can configure a value in the range from 1 through 255,000 milliseconds. You can also specify the minimum transmit and receive intervals separately.
![]() |
Note: If you specify a minimum interval for Bidirectional Forwarding Detection (BFD) less than 100 ms, the BFD session might transition down and up. On some routing platforms, it is safe to configure values below 100 ms. Please contact Juniper Networks customer support for more information. |
To specify only the minimum receive interval for failure detection, include the minimum-receive-interval statement:
- minimum-receive-interval milliseconds;
This value represents the minimum interval at which the local router expects to receive a reply from a neighbor with which it has established a BFD session. The values that you can configure are in the range from 1 through 255,000 milliseconds.
To specify the number of hello packets not received by a neighbor that causes the originating interface to be declared down, include the multiplier statement:
- multiplier number;
The default is 3, and you can configure a value in the range from 1 through 255.
To specify only the minimum transmit interval for failure detection, include the transmit-interval minimum-interval statement:
- transmit-interval {
- minimum-interval milliseconds;
- }
This value represents the minimum interval at which the local router transmits hello packets to the neighbor with which it has established a BFD session. You can configure a value in the range from 1 through 255,000 milliseconds.
To specify the threshold for detecting the adaptation of the transmit interval, include the transmit-interval threshold statement:
- transmit-interval {
- threshold milliseconds;
- }
The threshold value must be greater than the transmit interval.
To specify the BFD version used for detection, include the version statement:
- version (1 | automatic);
The default is to have the version detected automatically.
Beginning with JUNOS Release 9.0, you can configure BFD sessions not to adapt to changing network conditions. To disable BFD adaptation, include the no-adaptation statement:
- no-adaptation;
![]() |
Note: We recommend that you not disable BFD adaptation unless it is preferable not to have BFD adaptation enabled in your network. |
For a list of hierarchy levels at which you can include these statements, see the statement summary sections for these statements.