RIB, FIB, LIB and the Adjacency Table

RIB (Routing Information Base)
* Maintains the network toplogies and routing tables for each protocol.
* Would include many routes going to the same destination.
* Built on a per routing protocol basis.

FIB (Forwarding Information Base)
* Contains the best routes from the many routing protocol RIB's.
* Stored in fast hardware tables on platforms that support it (most modern switches)
* What you would see in the 'show ip route' command.
* One copy of the FIB per system for centralised forwarding platforms.
* One copy of the FIB per linecard in the case of a distibuted system.

LIB (Label Information Base)
* Used by IP/MPLS capable routers.
* Contains details of the port and corresponding MPLS router label to be popped or pushed on incoming out outgoing MPLS packets.
* Populated from label distribution protocols.
* Stored in Software.

Adjacency Tables

Routers and switches are considered adjacent if they can reach eachother with a single layer 2 hop. In addition to the FIB, CEF uses these adjacency tables to prepend layer 2 addressing information. In conclusion the adjacency table contains layer 2 next hope addresses for all FIB entries.