Routing table diagram showing route types and an example route from 172.16.17.0 to 10.2.2.2 via 10x Hop.

What is a Routing Table -Explained

Routing tables are the backbone of IP networking, guiding routers in forwarding data packets to their intended destinations efficiently. For CCNA and CCNP students, mastering routing tables is essential, as they form a core component of Cisco certification exams and real-world network administration. A routing table contains critical information about network paths, including directly connected and remote networks, and is used by routers to select the best path for packet forwarding.

This article provides a comprehensive guide to understanding routing tables, including their components, sources, configuration, and troubleshooting, tailored for CCNA and CCNP learners. We’ll cover practical Cisco IOS examples, key concepts like administrative distance and metrics, and tips to excel in your certification exams.

A routing table has information usually viewed in a table format to decide where to send data packets. All IP-enabled devices, including routers, direct a packet to the destination using routing tables.

The router gets route information from the routing table and selects the best path for the destination. Each packet has information about its source and destination. The router examines the packet and matches it to the routing table entry, providing the best match for its destination. Then, the router sends the packet to the next hop on its route across the network.

We can configure routes manually or dynamically. The static routes do not change unless a network administrator manually changes them, but the dynamic routes automatically update and change according to routing protocols. The routing protocols exchange information about the network topology and network changes and update the routing table.

Dynamic routing protocols also allow devices to listen to the network and react to occurrences like device failures and network congestion. The routing table is a data file storing route information about directly connected and remote networks.

  • Directly connected routes—When configuring and activating the interface, the router adds a directly connected route against the interface.
  • Remote routes—These are the routes from remote networks to other routers. We can configure these routes statically or dynamically.

Routing Table Sources

We can check the routing information on a Cisco router using the show ip route command. The router also provides additional route information, including the source of the route, with this command. The following are the different sources of the routing entries.

  • Local Route interfaces—The router adds the route when we configure and activate the router interface. This entry is available in all IOS for IPv6, but for IPv4, the option is available only in IOS 15 or newer versions.
  • Directly connected interfaces—The routes that were directly connected were added to the routing table when we activated and configured the interface.
  • Static routes– The static route is added to the routing table when a route is manually configured, and the exit interface is active.
  • Dynamic routing protocol—The routing protocols that dynamically learn the network’s information and add the information to the routing table, such as RIP, EIGRP, and OSPF.

We can find the routing entry sources with a code. The code tells us the source of the route information. The figure below illustrates the codes of the route sources, including the entries in a single route:

Routing Table Entries 1
What is a Routing Table -Explained 11

Route Source Codes

The show ip route command displays routing table entries with codes indicating their source. Below is a table of common route source codes:

CodeDescriptionExample Source
CDirectly connected networkInterface network
LLocal interface IP addressRouter’s own interface IP
SStatic routeManually configured route
DEIGRP-learned routeDynamic EIGRP protocol
OOSPF-learned routeDynamic OSPF protocol
RRIP-learned routeDynamic RIP protocol
S*Default static routeManually configured default

Remote Network Routing Entries

Understanding the content of an IPv4 and IPv6 routing table is most important. We have marked the route to the destination network 172.16.17.0 in the above figure. The marked entry for 172.16.17.0 identifies the following information:

  • Route source—This entry identifies how the router adds this route. In this example, the entry is “D”, meaning the router learns this route from the dynamic routing protocol EIGRP.
  • Destination network– This is the entry for remote network Identification. In this example, the remote network is 172.16.17.0.
  • Administrative distance—This is the trustworthiness of the route source. Lower values indicate a more trustworthy route to the destination network.
  • Metric—The metric is the cost of each available route, so the router selects the most cost-effective path. The Lower values indicate preferred routes to the destination.
  • Next-hop– This is the IPv4 address of the next connected router to send the packet.
  • Route timestamp– This entry shows the timing since the route was added.
  • Outgoing interface–This entry identifies the exit interface of the router that sends a packet toward the destination.

Directly Connected Interfaces

A newly installed router, without any configured and active interface, has an empty routing table, as shown in the figure below.

Screen Shot 2025 07 31 at 12.41.49 AM
What is a Routing Table -Explained 12

Before the interface state is up/up and added to the routing table, the interface must be assigned a valid IPv4 or IPv6 address and must not be shut down. It should also be able to receive the carrier signals from another device, e.g., router, switch, host, etc.

When the interface is up, the network of that interface is added automatically to the routing table as a directly connected network. For example, when we configure the interfaces of Router5 with IPv4 addresses and issue the no shutdown command, it receives the carrier signals from the router and hosts. It updates the routing table from an empty routing table, as shown in the figure below.

Directly Connected Routes (C) and Local Routes (L) Entries

When a router interface is configured with a valid IP address and activated (using no shutdown), it automatically adds two types of entries to the routing table:

Local Routes (L): Represent the specific IP address of the router’s interface (e.g., 172.16.19.1/32). These are used for packets destined to the router itself.

Directly Connected Routes (C): Represent the network directly attached to the interface. For example, if Router5’s interface is configured with 172.16.19.1/24, the network 172.16.19.0/24 is added as a “C” route.

Dirctly Connected Route 1
What is a Routing Table -Explained 13

Another route it is showing is the Local (L) route. The difference between Local and Directly connected routes is that a directly connected route is a route to a network that is directly attached to the interface and Local is the route that belongs to the router/switch itself in the above example you can see that in the directly connected route the destination is 172.16.19.0/24 address but the destination in Local route is 172.16.19.1 which is configured on the same Router (Router5)

Key Points:

  • Both C and L routes are added automatically when the interface is up.
  • No additional configuration is needed for these routes.
  • These entries are critical for routing packets to directly connected networks and the router’s interfaces.

Understanding IPv6 Routing Tables

IPv6 routing tables are similar to IPv4 but use 128-bit addresses and support modern network requirements. Here’s how IPv6 routing tables work on Cisco routers.

Key Differences from IPv4

  • Address Format: IPv6 uses 128-bit hexadecimal addresses (e.g., 2001:db8::/32) instead of 32-bit IPv4 addresses.
  • Route Sources: Same codes (C, L, S, O, D, etc.) apply, but IPv6 routes are displayed with show ipv6 route.
  • Configuration: IPv6 requires explicit enabling with ipv6 unicast-routing.

Example: Configuring and Verifying IPv6 Routes

Enable IPv6 routing:

Router(config)# ipv6 unicast-routing

Configure an IPv6 address on an interface:

Router(config)# interface GigabitEthernet0/0
Router(config-if)# ipv6 address 2001:db8:0:1::1/64
Router(config-if)# no shutdown

Verify the IPv6 routing table:

Router# show ipv6 route
C   2001:DB8:0:1::/64 [0/0]
    via GigabitEthernet0/0, directly connected
L   2001:DB8:0:1::1/128 [0/0]
    via GigabitEthernet0/0, local

Key IPv6 Routing Table Components

  • Route Source: Same as IPv4 (e.g., “C” for connected, “O” for OSPFv3).
  • Destination Network: The IPv6 prefix (e.g., 2001:db8:0:2::/64).
  • Next-Hop: The IPv6 address of the next router.
  • Outgoing Interface: The exit interface for the packet.

CCNA and CCNP Exam Tips for Routing Tables

Routing tables are heavily tested in CCNA and CCNP exams. Here are key tips and common question types:

Exam Tips

  • Understand Route Sources: Be able to identify C, L, S, D, O, and R codes in show ip route output.
  • Know Administrative Distance: Memorize default values (e.g., Connected: 0, Static: 1, EIGRP: 90, OSPF: 110, RIP: 120).
  • Practice Commands: Be proficient with show ip route, show ip protocols, and show running-config.
  • IPv6 Knowledge: For CCNP, expect questions on show ipv6 route and OSPFv3/EIGRP for IPv6.

Common Exam Questions

  1. Identify the Route Source: Given a show ip route output, determine whether a route is static, OSPF, or EIGRP.
  2. Troubleshoot Missing Routes: Diagnose why a route is missing using appropriate commands.
  3. Compare Metrics: Explain why a router chooses one route over another based on administrative distance or metrics.

Pro Tip: Use GNS3 or Packet Tracer to simulate routing tables and practice configuring static and dynamic routes.

Avatar of Mudassir K

Mudassir K

I am Mudassir ijaz and I am here to share my experience and expertise in writing. I've been writing articles for different publications for more than 6 years. My articles are published on sites like networkustad.com, editorialdiary.com, and articlebench.org. I have a varied range of interests and that's why I love blogging about different topics. In my opinion, blogging is a lot like acting, and I consider writing blog posts as an acting job. I am an entrepreneur by heart and there is nothing big or small when it comes to starting a business.