Bidirectional Forwarding Detection
Bidirectional Forwarding Detection (BFD) is a protocol to test if a connection is still active or if it is lost. This is very useful in case of Ethernet links, as well as for longer IP paths in case of MPLS.
BFD is a lightweight protocol that can be used in different modes for checking
if the connection is still up. For our use-case, the asynchronous mode is preferred.
In this mode, both sides send Hello packets.
Using BFD for link detection additionally to the keep-alive part
of the routing protocol, like BGP, has one benefit: the timeouts are tremendously
lower and therefore a switch to a healthy route is much faster.
In comparison, the timeout of common BGP sessions can range to 240s and might
be reduced to 30s, the BFD timeouts can range to <1s.
Therefore, it is advised to switch on BFD for link detection wherever possible.