# Network Layer – Routing 2 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF.

## Presentation on theme: "Network Layer – Routing 2 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF."— Presentation transcript:

Network Layer – Routing 2 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF

Adaptive or Dynamic Routing There are three main strategies: Isolated Adaptive: Each node has only local information and decision is taken at each node (distributed control). Distance Vector Routing: Each node receives information from adjacent nodes and there is distributed control. Link State Routing: Each node receives information from all other nodes and there is distributed control.

Distance Vector Routing Each node exchanges its delay vectors with its neighbor nodes. Based on this information a node tries to estimate the delay situation throughout the network. E.g. RIP of the Internet (originally used in the ARPANET) Drawbacks: Although this algorithm converges to the correct answer, it may do so slowly. It reacts rapidly to good news, but leisurely to bad news. This is also referred to as the Count- to-Infinity problem. Also, Distance Vector Routing does not scale well as the delay vectors get too big as the network size increases.

Distance Vector Routing - Example 9 3 9

Distance Vector Routing Measured delay from Node 1 to its neighbors are as follows: Node 2: 2Node 3: 5Node 4: 1 Node 1’s routing table Delay Vectors (D2, Node 1’s routing table before update D3, D4 from neighbors) after update (using Dijkstra’s algorithm) Destination node Delay (Cost)Next node 10- 222 353 414 563 683 D2 2 0 3 2 3 5 D3 3 3 0 2 1 3 D4 1 2 2 0 1 3 Destination node Delay (Cost)Next node 10- 222 334 414 524 644

Drawback of Distance Vector Routing: Count-to-Infinity Problem Although this approach to routing converges to the correct answer, it may do so slowly. It reacts rapidly to good news, but leisurely to bad news. Good news of a path to A spreads quickly Bad news of no path to A is learned slowly

Link State Routing Distance Vector does not scale well as the delay vectors get too big as the network size increases. It also experiences the Count-to-Infinity Problem. Hence it has been replaced by Link State Routing on the Internet. Link State Routing has 5 parts. Each router must: 1. Discover its neighbors and learn their network addresses. Send a HELLO packet to its neighbors. The response packet contains the neighbor’s IP address. 2. Measure the delay or cost to each of its neighbors. Send an ECHO packet to its neighbors and measure the RTT. Delay = RTT/2. 3. Construct a packet (Link State Packet (LSP)) telling all it just learnt. 4. Send this packet to all other routers. 5. Compute the shortest path to every other router using Dijkstra’s algorithm.

Link State Routing – Building LSP packets Building LSP packets A router builds a LSP packet containing identity of sender, sequence # and age of packet, and list of neighbors along with delays to reach them. Network LSP for each node

Link State Routing – Distributing Link State Packets (LSPs) Flooding is used to ensure that all routers in the subnet receive LSP packets. Each LSP contains a sequence #. Receiving routers keep track of pairs they see. If a router crashes and comes back up later, it starts with sequence # 0. So the next packet will be rejected as being obsolete. To prevent this, the age is included in the LSP.

Link State Routing – Computing New Routes Once a router has accumulated a full set of LSPs, it can construct the entire subnet graph because every link is represented. Then it runs Dijkstra’s algorithm to determine the shortest path to all other routers. E.g. of Link State Routing is Open Shortest Path First (OSPF) in the Network Layer in the Internet.

Differences between Distance Vector and Link State Routing 1. The delay vector in Distance Vector Routing contains delay information to get to all other routers but is sent only to its neighboring nodes. 2. The LSP in Link State Routing only contains delay information to get to its neighboring nodes but is sent to out to all other routers in the subnet. 3. Link State Routing is more scalable because its LSPs only contain delay information to the neighboring nodes rather than all other routers.

Download ppt "Network Layer – Routing 2 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF."

Similar presentations