Difference between routing-table and forwarding-table

Discussion in 'Cisco' started by Joachim Krais, Nov 21, 2003.

  1. Hallo,
    I read some articles about routers and I found explanations about this two
    terms:
    routing-table and forwarding-table.

    But in the articles stand sometimes too difference information, so that I
    doesn't know
    the right definition about these tables.

    What's the exactly definition about a routing-table and a forwarding-table?
    Are these tables the same?
    What are the really elements of these two tables and what's the use of these
    tables?

    Thank You.
     
    Joachim Krais, Nov 21, 2003
    #1
    1. Advertisements

  2. :I read some articles about routers and I found explanations about this two
    :terms:
    :routing-table and forwarding-table.

    :But in the articles stand sometimes too difference information, so that I
    :doesn't know
    :the right definition about these tables.

    :What's the exactly definition about a routing-table and a forwarding-table?
    :Are these tables the same?

    Looking around the net a small bit, I find RFC1354 which says,

    -- IP Forwarding Table

    -- The IP Forwarding Table obsoletes and replaces the ipRoute
    -- Table current in MIB-I and MIB-II. It adds knowledge of
    -- the autonomous system of the next hop, multiple next hop
    -- support, and policy routing support.

    The description there for an ipForwardEntry is,

    "A particular route to a particular destination, under a particular
    policy."


    Traditionally, a routing table did not take policy into account.
     
    Walter Roberson, Nov 21, 2003
    #2
    1. Advertisements

  3. Joachim Krais

    Andre Beck Guest

    Exact definitions? I doubt there are any, as this is not pure ISO/OSI
    theory ;)
    To some extend, they represend the same thing: A ruleset for forwarding
    packets. The question is, on which layer of abstraction they exist. This
    even differs from vendor to vendor (what some call a routing table is
    more a forwarding table, and vice versa).
    I see it this way: The routing table is an abstract description of
    forwarding rules, consisting of prefixes and the information via
    which interface (and maybe gateway) they have to leave the router
    in order to get closer to their destination. This information may
    be recursive and it may refer to additional information in other
    data structures. Looking up the routing table is somewhat complicated
    and thus time consuming.

    The forward table is a simplicated and sometimes specifically com-
    pacted representation of the routing table that allows for much
    cheaper lookups. All recursions should be solved, all additional
    data taken into account or eliminated. The forwarding table allows
    for much faster CPU forwarding, and it may be implemented partially
    or entirely in hardware (CAM, TCAM, ASICs etc). Cisco has an imple-
    mentation of a forwarding table they call CEF.

    So in short, the FT is a precompiled and unrolled RT that basically
    consists of rows like

    prefix egress-if
    prefix egress-if
    [...]

    and matches certain prefixes against the interface on which they should
    leave the router. Of course it is no linear list but a multi level
    data structure or something else that allows for very fast matches,
    keeping in mind the IP classless rules (most specific prefix wins).
    It will be compiled from the RT at certain intervals, downloaded
    to the forwarding engines (you see, it is also a key element in distri-
    buted router implementations) and the forwarding engines just refer
    to it, not to the RT.

    For a nice discussion of some compact FT schemes, see here:

    http://www.bell-labs.com/user/stiliadi/router/node4.html

    BTW, with Ciscos, the RT is already a compiled representation of
    information that comes from above: The connected and static routes
    with their preferences, the tables collected by IGPs and EGPs. This
    is implementation specific, there are others who try to incorporate
    all that into a (more abstract) RT and are thus even more required to
    later compile it into an easy to handle FT.
     
    Andre Beck, Nov 23, 2003
    #3
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.