EdgeRouter - Route lifecycle

Overview


Readers will learn about the routing protocol daemons for EdgeOS. Given the existent of routing protocol daemons, the forwarding database does not accumulate in a one-step process.

Terms and abbreviations used in this article:

  • RIB — Routing Information Base, an entity that stores all available routes.
  • FIB — Forwarding Information Base, an entity that stores routes actually used for traffic forwarding.
  1. Routing protocol processes receive routing information from peers. They may or may not accept it depending on their filtering policy configuration or information validity. Some of the routes may be accepted into protocol-specific routing table but not propagated to RIB (e.g. if there are several routes to the same destination with, only the best ones may be sent to RIB).
  2. If routing protocol process accepts routing information and selects the route as FIB candidate, it sends it to the RIB process.
  3. RIB installs routes to the FIB. Or, under certain circumstances, does not install.

Therefore if you need to debug routing, you should look at routing process specific database, then the RIB, and then FIB.

  1. Routing process database commands are protocol specific. For BGP it is "show ip bgp", for RIP it is "show ip rip", for OSPF they are "show ip ospf route" and for LSAs — "show ip ospf database"
  2. To view RIB routes, use "show ip route"
  3. To view FIB routes, use "show ip route forward"

Examples


One example of the case when RIB will not install a route into FIB is when its next hop is unreachable. Try the following (given you don't have a route to 192.0.2.1):

ubnt@ubnt# set protocols static route 192.0.2.0/24 next-hop 192.0.2.1
ubnt@ubnt# commit
ubnt@ubnt# run show ip route
Codes: K - kernel route, C - connected, S - static, R - RIP, O - OSPF,
 I - ISIS, B - BGP, > - selected route, * - FIB route
...
S 192.0.2.0/24 [1/0] via 192.0.2.1 inactive
ubnt@ubnt# run show ip route forward | match 192.0.2.0/24
<no output>

There are also examples when RIB will modify route entries before installing them into FIB. One example is recursive route, where its next hop is not directly reachable, but is reachable via a reachable host. In this case you may see something like:

ubnt@ubnt# show ip route
...
S>* 10.46.0.0/16 [1/0] via 10.91.18.10 (recursive via 10.91.19.1)
...
ubnt@ubnt# show ip route forward
...
10.46.0.0/16 via 10.91.19.1 dev eth0 proto zebra
...

Note: zebra is the name of EdgeOS RIB daemon.

Powered by Zendesk