BGP Flashcards
(15 cards)
RIBs
Routes are stored in Routing information Bases
RIB-in:
Routing information learned from inbound update messages
Contains unprocessed routing info advertised to the local BGP speaker by its peers
Local RIB:
Routing info the the BGP speaker selects after applying its local policies to the RIB-in
RIB-out:
Routing info that the local BGP speaker selects to advertise to its peers
BGP Attributes
Well-known mandatory. (Origin, AS_PATH, NEXT_HOP)
Well-know discretionary (optional) (LOCAL_PREF, ATOMIC_AGGREGATE)
Optional transitive - optional and can be passed outside of the local AS (AGGREGATOR, COMMUNITY)
Optional non-transitive:
optional and can NOT be passed outside of the local AS (MULTI_EXIT_DISC)
BGP Route Selection Tie Breakers
- Highest Weight
- Highest local preference
- Route originated by the local router (next hop = 0.0.0.0)
- Shortest AS path
- Lowest origin type
- Lowest multi-exit discriminator (MED)
- Prefer external paths (EBGP) over internal paths (IBGP)
- Path through closest IGP neighbor
- Oldest route for EBGP paths
- Lowest neighbor BGP router ID
- Lowest neighbor IP address
BGP states
Idle: Initial State
Connect: Waiting for a successful three-way TCP connection
Active: Unable to establish TCP session
OpenSent: Waiting for an OPEN message from the peer
OpenConfirm: Waiting for the keepalive message from the peer
Established: Peers have successfully exchanged OPEN and keepalive messages
BGP summary command
get router info bgp summary
Columns-
AS - Remote AS
MsgRcvd and MsgSent - Packet count received/sent
Up/Down - How long the connection has been up
State/PfxRcd - Neighbor state and prefixers received
BGP neighbors command
get router info bgp neighbors
Command to see prefixes advertised by local FGT
get router info bgp neighbors (local IP address) advertised-routes
Command to see prefixes advertised by Neighbor
get router info bgp neighbors (neighbor IP) route
Command to show prefixes by All BGP Peers
get router info bgp network
Origin codes -
i = IBGP, indicates the network command was used to advertise a route.
? = incomplete, indicates the the route was advertised from another routing protocol using redistribution
e = EBGP, legacy route advertisement
BGP event logging
enabled by default:
config router bgp
set log-neighbour-change enable | disable
end
Shows these events:
Neighbor down/up
RIB update
BGP message exchange
Errors connecting to neighbors
can be seen in GUI under Log & Report > System Events > Router Events
Port for BGP
TCP/179
Real-time Debug command for BGP
diagnose ip router bgp all enable
diagnose ip router bgp level info
diagnose debug enable
to disable:
diagnose ip router bgp all disable
diagnose ip router bgp level none
diagnose debug enable
diagnose debug reset does NOT stop BGP bebug
Restart BGP commands
execute router clear bgp (options)
all (arguments)
in
in prefix-filter
out
-These resets BGP process and requires FGT to establish BGP peering again
soft (in|out) - Resends complete BGP table
network-import-check
can disable, that allows FortiOS to advertise falsely configured routes (not recommended)
T or F: Prefix list rules are all inspected unlike firewall policies
True