Forwarding && Routing
Forwarding consists of taking a packet, looking at its destination
address, consulting a table, and sending the packet in a direction determined by that table.forwarding is a relatively simple and well-defined process performed locally at a node, whereas routing depends on complex distributed algorithms that have continued to evolve throughout the history of networking.
routing table usually just contains mapping from network prefixes to next hops.
the 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.
Theforwarding table is used when a packet is being forwarded and so must contain enough information to accomplish the forwarding function. This means that 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. The routing table, on the other hand, is the 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 algorithms
IGPs(Intra domain Protocals/Interior gateway protocal) can’t scale very well for large size network.
Routing domain: an internetwork where all router are under single administrative control.
Basic:shortest path problems. calculating all shortest paths and store them into each node table.
Usually use distributed algorithms to run on all nodes.
1.distance vector:RIP(Bellman-ford),
The next step in distance-vector routing is that every node sends a message to its directly connected neighbors containing its personal list of distances. The process of getting all nodes getting consistent information about routes is called convergence. Each nodes only know about its own table.
Whenever routing table changed or some link get failed, will notify its neighbors and updated the table. node continually detects whether a link is working by continually sending control packets and receiving acknowledgements.
2.link state: