Routing vs Forwarding

both routing and forwarding together helps determine how an IP packet is sent from source to destination

  • routing - the process of building up the routing-tables to allow correct forwarding
  • forwarding - the process of taking a packet from input and sending it out on the appropriate output

Routing Tables vs Forwarding Tables

forwarding-table needs to be structured to optimize the process of looking up an address when forwarding a packet, while the routing-table needs to be optimized for the purpose of calculating changes in topology

  • routing table - a table that is built up by the routing algorithms as a precursor to building the forwarding table. It generally contains mappings from network prefixes to next hops. It may also contain information about how this information was learned, so that the router will be able to decide when it should discard some information
    • routing tables itself can have 2 types:
      • unicast routing table - for unicast forwarding
      • multicast routing table - for multicast forwarding
  • forwarding table - is used when a packet is being forwarded. a row in the forwarding table contains the mapping from a network prefix to an outgoing interface and some MAC information, such as the Ethernet address of the next hop.