Cisco Express Forwarding (CEF) is a Cisco proprietary Layer 3 IP switching technology. CEF optimizes network performance and scalability for networks with large and dynamic traffic patterns, such as the Internet. It is most suitable on networks characterized by intensive Web-based applications, or real-time inter-active use such as video conferencing sessions.
CEF offers the following benefits
Improved performance: By design, CEF is less CPU-intensive than fast switching route caching. By using CEF, more CPU processing power can be utilized to Layer 3 services such as quality of service (QoS) and encryption.
Scalability: CEF offers full switching capacity at each line card when dCEF mode is active, thus ensuring scalability of operation.
Resilience: CEF aims at providing better switching consistency and stability in large dynamic networks. In dynamic networks, fast-switched cache entries are frequently invalidated due to routing changes. These changes can cause traffic to be process switched using the routing table, rather than fast switched using the route cache. Because the Forwarding Information Base (FIB) lookup table contains all known routes that exist in the routing table, it eliminates frequent route cache maintenance, thereby enabling CEF to switch traffic more efficiently than typical demand caching schemes.
CEF Components: The two main components of CEF are
FIB (Forwarding Information Base): CEF uses an FIB to make IP destination prefix-based switching decisions. The FIB is conceptually similar to a routing table or information base. It maintains a mirror image of the forwarding information contained in the IP routing table. When routing or topology changes occur in the network, the IP routing table is updated, and those changes are reflected in the FIB. The FIB maintains next hop address information based on the information in the IP routing table. Because there is a one-to-one correlation between FIB entries and routing table entries, the FIB contains all known routes and eliminates the need for route cache maintenance that is associated with switching paths such as fast switching and optimum switching.
Adjacency Tables: Nodes in the network are said to be adjacent if they can reach each other with a single hop across a link layer. In addition to the FIB, CEF uses adjacency tables to prepend Layer 2 addressing information. The adjacency table maintains Layer 2 next-hop addresses for all FIB entries.