FortiGate
FortiGate Next Generation Firewall utilizes purpose-built security processors and threat intelligence security services from FortiGuard labs to deliver top-rated protection and high performance, including encrypted traffic.
GeorgeZhong
Staff & Editor
Staff & Editor
Article Id 419310
Description This article describes the meaning of the different 'registered protocols' in the output of 'get router info bfd neighbor detail'. This helps to understand that the BFD neighborship is established based on which protocol.
Scope FortiGate, BFD.
Solution

Bidirectional Forwarding Detection (BFD) is a protocol that helps to quickly locate hardware failures in the network. Routers running BFD send packets to each other at a negotiated rate. If packets from a BFD-enabled router fail to arrive, that router is declared to be down. BFD communicates this information to the associated routing protocols, and the routing information is updated. It helps detect one-way device failure and is used for fast convergence of routing protocols.

 

BFD can be configured at the device level, interface level, or routing protocol level. Detailed information related to BFD can be found in below official document:

Bidirectional Forwarding Detection (BFD) 

 

The command 'get router info bfd neighbor detail' can be used to identify which level the BFD neighbor relationship is configured.

 

Example 1: device-level BFD neighbor.

BFD neighbor on FortiGate-A can be configured at the device-level as follows:

 

config router bfd
    config neighbor
        edit 10.56.242.129
            set interface "port1"
        next
    end
end

 

The FortiGate-B on the remote end has the same BFD setting:

 

config router bfd
    config neighbor
        edit 10.56.242.195
            set interface "port1"
        next
    end
end

 

The BFD will come up once both ends can connect with each other to share the BFD packets. The output of BFD neighbor detail will be as follows. The Registered Protocol will be 'Static', which means a static BFD neighbor rather than a static route. 

 

site1 (root) # get router info bfd neighbor detail

OurAddress NeighAddress State Interface LDesc/RDesc
10.56.242.195 10.56.242.129 UP port1 1/1
Local Diag: 0, Demand mode: no, Poll bit: unset
MinTxInt: 250, MinRxInt: 250, Multiplier: 3
Received: MinRxInt: 250 (ms), MinTxInt: 250 (ms),Multiplier: 3
Transmit Interval: 250 (ms), Detection Time: 750 (ms)
Rx Count: 396880, Rx Interval (ms) min/max/avg 0/910/130 last 180 (ms) ago
Tx Count: 396943, Tx Interval (ms) min/max/avg 0/810/120 last: 90 (ms) ago
Registered protocols: Static

 

Example 2: BFD on a static route.

Instead of configuring the static BFD neighbor, BFD can also be enabled on the static route as follows on FortiGate-A:

 

config router static
    edit 1
        set gateway 10.56.242.129
        set device "port1"
        set bfd enable
    next
end

 

The FortiGate-B on the remote end still has a static BFD neighbor configured:

 

config router bfd
    config neighbor
        edit 10.56.242.195
            set interface "port1"
        next
    end
end

 

With this setup, FortiGate-A will try to establish the BFD neighbor with the gateway IP 10.56.242.129 in the static route. Since the port1 on FortiGate-B has this IP and is with the BFD enabled, the BFD will form as well. The neighbor's details will be as follows. The 'Registered Protocol' for the static route will be 'External' rather than 'Static'. 

 

site1 (root) # get router info bfd neighbor detail

OurAddress NeighAddress State Interface LDesc/RDesc
10.56.242.195 10.56.242.129 UP port1 1/1
Local Diag: 0, Demand mode: no, Poll bit: unset
MinTxInt: 250, MinRxInt: 250, Multiplier: 3
Received: MinRxInt: 250 (ms), MinTxInt: 250 (ms),Multiplier: 3
Transmit Interval: 250 (ms), Detection Time: 750 (ms)
Rx Count: 399163, Rx Interval (ms) min/max/avg 0/910/130 last 50 (ms) ago
Tx Count: 399216, Tx Interval (ms) min/max/avg 0/810/120 last: 50 (ms) ago
Registered protocols: External

 

Example 3: BFD on BGP.

The BFD can be enabled on the BGP neighbor as well as on FortiGate-A. 

 

config router bgp
    config neighbor
        edit 10.56.242.129
            set bfd enable
        next
    end
end

 

Assume the BFD setting on FortiGate-B is still the same as before. The BFD neighbor detail on FortiGate-A will be as follows. The Registered protocols are changed to BGP, which indicates the BFD neighbor is established for the BGP protocol.

 

site1 (root) # get router info bfd neighbor de

OurAddress NeighAddress State Interface LDesc/RDesc
10.56.242.195 10.56.242.129 UP port1 1/1
Local Diag: 0, Demand mode: no, Poll bit: unset
MinTxInt: 250, MinRxInt: 250, Multiplier: 3
Received: MinRxInt: 250 (ms), MinTxInt: 250 (ms),Multiplier: 3
Transmit Interval: 250 (ms), Detection Time: 750 (ms)
Rx Count: 402396, Rx Interval (ms) min/max/avg 0/910/130 last 20 (ms) ago
Tx Count: 402448, Tx Interval (ms) min/max/avg 0/810/120 last: 120 (ms) ago
Registered protocols: BGP

 

Example 4: BFD on OSPF.

The BFD can be used in the OSPF setting as well to monitor the OSPF neighbor status. It needs to be enabled in both the global OSPF setting and the OSPF interface setting:

 

FortiGate-A configuration:

 

config router ospf
    set bfd enable
        config ospf-interface
            edit "port1"
                set interface "port1"
                set bfd enable
            next
        end

end

 

Assume the configuration of FortiGate-B remains the same. The BFD neighbor detail on FortiGate-A will be as follows. The Registered protocols are changed to OSPF, which indicates the BFD neighbor is established for the OSPF protocol.

 

site1 (root) # get router info bfd neighbor detail

OurAddress NeighAddress State Interface LDesc/RDesc
10.56.242.195 10.56.242.129 UP port1 1/1
Local Diag: 0, Demand mode: no, Poll bit: unset
MinTxInt: 250, MinRxInt: 250, Multiplier: 3
Received: MinRxInt: 250 (ms), MinTxInt: 250 (ms),Multiplier: 3
Transmit Interval: 250 (ms), Detection Time: 750 (ms)
Rx Count: 406866, Rx Interval (ms) min/max/avg 0/910/130 last 10 (ms) ago
Tx Count: 406919, Tx Interval (ms) min/max/avg 0/810/120 last: 200 (ms) ago
Registered protocols: OSPF

 

The same BFD neighbor can also be established for multiple protocols. Assume the FortiGate-A has a BFD configuration shown in example 1-4; at the same time, the BFD neighbor will be established for all these protocols. The neighbor detail will display all protocols as registered protocols as below:

 

site1 (root) # get router info bfd neighbor detail

OurAddress NeighAddress State Interface LDesc/RDesc
10.56.242.195 10.56.242.129 UP port1 1/1
Local Diag: 0, Demand mode: no, Poll bit: unset
MinTxInt: 250, MinRxInt: 250, Multiplier: 3
Received: MinRxInt: 250 (ms), MinTxInt: 250 (ms),Multiplier: 3
Transmit Interval: 250 (ms), Detection Time: 750 (ms)
Rx Count: 406866, Rx Interval (ms) min/max/avg 0/910/130 last 10 (ms) ago
Tx Count: 406919, Tx Interval (ms) min/max/avg 0/810/120 last: 200 (ms) ago
Registered protocols: External Static OSPF BGP

 

Related articles:

Technical Tip: Configuring Bidirectional Forwarding Detection (BFD) for static routes 

Technical Tip: FortiGate BFD implementation and examples (Bidirectional Forwarding Detection for OSP...