Intradomain Routing EECS 122: Lecture 10 Department of Electrical Engineering and Computer Sciences University of California Berkeley.

Slides:



Advertisements
Similar presentations
1 Routing Protocols I. 2 Routing Recall: There are two parts to routing IP packets: 1. How to pass a packet from an input interface to the output interface.
Advertisements

Network Layer – Routing 2 Dr. Sanjay P. Ahuja, Ph.D. Fidelity National Financial Distinguished Professor of CIS School of Computing, UNF.
Chapter 4 Distributed Bellman-Ford Routing
COS 461 Fall 1997 Routing COS 461 Fall 1997 Typical Structure.
Courtesy: Nick McKeown, Stanford
Routing - I Important concepts: link state based routing, distance vector based routing.
Networks: Routing1 Network Layer Routing. Networks: Routing2 Network Layer Concerned with getting packets from source to destination Network layer must.
EECS122 Midterm Review Department of Electrical Engineering and Computer Sciences University of California Berkeley.
CSE331: Introduction to Networks and Security Lecture 9 Fall 2002.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 22 Introduction to Computer Networks.
15-744: Computer Networking L-5 Intra-Domain Routing.
Communication Networks A Second Course Jean Walrand Department of EECS University of California at Berkeley.
Katz, Stoica F04 EECS 122: Introduction to Computer Networks Link State and Distance Vector Routing Computer Science Division Department of Electrical.
Spring Routing & Switching Umar Kalim Dept. of Communication Systems Engineering 06/04/2007.
1 Computer Networks Routing Algorithms. 2 IP Packet Delivery Two Processes are required to accomplish IP packet delivery: –Routing discovering and selecting.
EE 122: Intra-domain routing Ion Stoica September 30, 2002 (* this presentation is based on the on-line slides of J. Kurose & K. Rose)
EECC694 - Shaaban #1 lec #7 Spring The OSI Reference Model Network Layer.
CSE 461: Link State Routing. Link State Routing  Same assumptions/goals, but different idea than DV:  Tell all routers the topology and have each compute.
Networks: Routing1 Network Layer Routing. Networks: Routing2 Network Layer Concerned with getting packets from source to destination. The network layer.
CS 4700 / CS 5700 Network Fundamentals Lecture 9: Intra Domain Routing Revised 7/30/13.
ROUTING ON THE INTERNET COSC Aug-15. Routing Protocols  routers receive and forward packets  make decisions based on knowledge of topology.
CECS 474 Computer Network Interoperability WAN Technologies & Routing
Routing Algorithms (Ch5 of Computer Network by A. Tanenbaum)
1 Pertemuan 20 Teknik Routing Matakuliah: H0174/Jaringan Komputer Tahun: 2006 Versi: 1/0.
CS551: Unicast Routing Christos Papadopoulos (
Network Layer r Introduction r Datagram networks r IP: Internet Protocol m Datagram format m IPv4 addressing m ICMP r What’s inside a router r Routing.
Spring 2008CS 3321 Intradomain Routing Outline Algorithms Scalability.
Routing Protocols RIP, OSPF, BGP. A Routing Protocol’s Job Is to Find a “Best” Path between Any Pair of Nodes Routers in a network exchange their routing.
Link-state routing  each node knows network topology and cost of each link  quasi-centralized: each router periodically broadcasts costs of attached.
Network and Communications Ju Wang Chapter 5 Routing Algorithm Adopted from Choi’s notes Virginia Commonwealth University.
Network Layer4-1 Chapter 4: Network Layer r 4. 1 Introduction r 4.2 Virtual circuit and datagram networks r 4.3 What’s inside a router r 4.4 IP: Internet.
Chi-Cheng Lin, Winona State University CS 313 Introduction to Computer Networking & Telecommunication Chapter 5 Network Layer.
1 Week 5 Lecture 2 IP Layer. 2 Network layer functions transport packet from sending to receiving hosts transport packet from sending to receiving hosts.
Distance Vector Routing
Network Layer4-1 Distance Vector: link cost changes Link cost changes: r node detects local link cost change r updates distance table (line 15) r if cost.
Spring 2006CS 3321 Intradomain Routing Outline Algorithms Scalability.
Routing and Routing Protocols
1 Computer Communication & Networks Lecture 21 Network Layer: Delivery, Forwarding, Routing Waleed.
Internet Routing r Routing algorithms m Link state m Distance Vector m Hierarchical routing r Routing protocols m RIP m OSPF m BGP.
Computer Networks22-1 Network Layer Delivery, Forwarding, and Routing.
Ch 22. Routing Direct and Indirect Delivery.
Spring 2000CS 4611 Routing Outline Algorithms Scalability.
Graph Algorithms Why graph algorithms ? It is not a “graph theory” course! Many problems in networks can be modeled as graph problems. Note that -The topology.
1 Chapter 4: Internetworking (IP Routing) Dr. Rocky K. C. Chang 16 March 2004.
Network Layer (2). Review Physical layer: move bits between physically connected stations Data link layer: move frames between physically connected stations.
CS 6401 Intra-domain Routing Outline Introduction to Routing Distance Vector Algorithm.
CSE 421 Computer Networks. Network Layer 4-2 Chapter 4: Network Layer r 4. 1 Introduction r 4.2 Virtual circuit and datagram networks r 4.3 What’s inside.
Network Layer Routing Networks: Routing.
Network Layer.
CS 5565 Network Architecture and Protocols
CSE390 – Advanced Computer Networks
THE NETWORK LAYER.
Network Layer Introduction Datagram networks IP: Internet Protocol
Intra-Domain Routing Jacob Strauss September 14, 2006.
Routing: Distance Vector Algorithm
(How the routers’ tables are filled in)
Routing in Packet Networks Shortest Path Routing
CS 4700 / CS 5700 Network Fundamentals
CS 3700 Networks and Distributed Systems
Intradomain Routing Outline Introduction to Routing
ECE453 – Introduction to Computer Networks
CS 3700 Networks and Distributed Systems
Network Layer Routing Networks: Routing.
Delivery, Forwarding, and Routing
Network Layer (contd.) Routing
EE 122: Intra-domain routing: Distance Vector
Network Layer.
CSE 461: Link State Routing
EE 122: Intra-domain routing: Link State
Network Layer Routing.
Presentation transcript:

Intradomain Routing EECS 122: Lecture 10 Department of Electrical Engineering and Computer Sciences University of California Berkeley

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 2 What is Routing? Routing is the core function of a network It ensures that information accepted for transfer at a source node is delivered to the correct set of destination nodes, at reasonable levels of performance.

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 3 Datagram v/s Virtual Circuit Datagram routing  Each packet to be forwarded independently Virtual Circuit  Each packet from same o-d uses same route  More state (pick the “right” granularity) QoS sensitive networks use VC’s and signaling  Find a route that has the resources available for the connection.  “Reserve” the resources before sending data packets

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 4 Many Kinds of Routing Driven by… Destination set  IP point-to-point  Multicast Physical Characteristics  Optical  mobile wireless  Diffusion (sensor networks)  Interconnection network routing  Geographic (wireless) Network Function  P2P  Content Distribution Networks

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 5 A Graph Model Nodes are Routers/Hosts Edges are undirected

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 6 Walks A Walk from 1 to 11 Cycle

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 7 Paths Routes are Paths A Path is a Walk with no cycles There are 24 paths from 1 to 11

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 8 Routes Routes are Paths A Path is a Walk with no cycles There are 24 paths from 1 to 11 Edges have weights

February 20, 2003 Abhay Parekh: EECS 122 Lecture 10 9 Routing Routes are Paths A Path is a Walk with no cycles There are 24 paths from 1 to 11 Edges have weights Select the shortest path route Many ways to do this

February 20, 2003 Abhay Parekh: EECS 122 Lecture Routing affects Flow Control Any function that “paces” the flow of bits into or within the network is flow control Example: All links have capacity 1 A D B 1 C A D B 1 C 1 Nothing admitted F E F E

February 20, 2003 Abhay Parekh: EECS 122 Lecture What is going on? Routing and flow intimately related  Link congestion metrics for routing depends on flow control  Flow control feedback delay depends on routing Optimizing them jointly is nice in theory but intractable in practice. Separating flow control and routing makes both extremely difficult to implement with high performance

February 20, 2003 Abhay Parekh: EECS 122 Lecture The internet has many Administrative Domains A B C

February 20, 2003 Abhay Parekh: EECS 122 Lecture Border Routers A B C OSPF RIP IGRP BGP

February 20, 2003 Abhay Parekh: EECS 122 Lecture Hierarchical Routing A B C B OSPF RIP IGRP BGP InterDomain IntraDomain

February 20, 2003 Abhay Parekh: EECS 122 Lecture Routing Sub-Functions Topology Update: Characterize and maintain connectivity  Discover neighbors  Measure “distance” (one or more metric)  Disseminate Route Computation:  Kind of path: Multicast, Unicast  Centralized or Distributed Algorithm  Policy  Hierarchy Switching: Forward the packets at each node

February 20, 2003 Abhay Parekh: EECS 122 Lecture Routing Sub-Functions Topology Update: Characterize and maintain connectivity  Discover neighbors  Measure “distance” (one or more metric)  Disseminate Route Computation:  Kind of path: Multicast, Unicast  Centralized or Distributed Algorithm  Policy  Hierarchy Switching: Forward the packets at each node

February 20, 2003 Abhay Parekh: EECS 122 Lecture Three types of Routing Protocols Topology changes can be detected by nearby nodes  These changes must be reflected in the routes Mechanisms for disseminating information  Link State: Communicate the names and costs of neighbors. Each node maintains the entire topology. E.g. used in OSPF  Distance Vector: Communicate current distance estimates of node to every other node. E.g. used in RIP  Path Vector: Communicate current estimates of preferred paths from node to every other node. E.g. used in BGP

February 20, 2003 Abhay Parekh: EECS 122 Lecture Link State Protocols 1. Every node learns the topology of the network Flooding of Link State Packets (LSP) 2. An efficient shortest path algorithm computes routes to every other node 3. Node updates Forwarding Table

February 20, 2003 Abhay Parekh: EECS 122 Lecture Flooding Link State Information Every router sends Link State Packets (LSPs) to all of its neighbors LSPs arrive and wait in buffers to be “accepted” If node j receives a LSP from node k it compares the sequence numbers. If this is the most recent one from k, send to N(j)-{k}.  This way each router can send its LSP to all other routers Age starts out at 7. At any router, value is decremented every 8 seconds. At 0 discard. As long as sequence don’t wrap this works  Otherwise things can get ugly Source Sequence Number Age List of Neighbors

February 20, 2003 Abhay Parekh: EECS 122 Lecture Example Network

February 20, 2003 Abhay Parekh: EECS 122 Lecture Example Network

February 20, 2003 Abhay Parekh: EECS 122 Lecture Example Network

February 20, 2003 Abhay Parekh: EECS 122 Lecture Example Network

October 9, 2002 Abhay K. Parekh: Topics in Routing 24 Real story… Sequence numbers from some router, s, wrapped around  A < B < C < A Router, t, has a buffer with LSPs from s of all three values in order: A, B, C  Store and flood A  Replace A with B and flood B  Replace B with C and flood C Router u receives the LSPs in order ABC and goes through the same cycle and sends to v The entire Arpanet was sending these LSPs and crashed LSPs did not wait in buffers long enough to age…

February 20, 2003 Abhay Parekh: EECS 122 Lecture Some Issues What happens if some routers are much faster at transmitting LSPs? What happens if sequence numbers wrap? What happens when a partitioned network is reconstituted? What about security? Etc., etc. Many lines of code

February 20, 2003 Abhay Parekh: EECS 122 Lecture Route Computation: Dijkstra Every node knows the graph  All link weights are >= 0 Goal at node 1: Find the shortest paths from 1 to all the other nodes. Each node computes the same shortest paths so they all agree on the routes Strategy at node 1: Find the shortest paths in order of increasing path length

February 20, 2003 Abhay Parekh: EECS 122 Lecture Dijkstra: Shortest Path D(1,5)=2 D(1,6,5)=5 P(2)={1,2} Notation c(i,j) >=0 :cost of link from (I,j) D(1,i): Shortest path from 1 to i. D(1,x,i): Shortest path from 1 to i via x Let P(k) be the set of nodes k-closest to 1 IDEA: Given P(k) we can find P(k+1) efficiently: To get P(k+1), observe that 1. This node cannot be in P(k) 2. It must be one hop away from some node in P(k) Suppose 2 were false. We picked i  Node i has no edge into P(k)  There must be a node x, not in P(k) such that x is one hop away from P(k) and D(1,i)=D(1,x)+D(x,i)  But then, D(1,x) < D(1,i) and we would have picked x instead. Pick node(s) that is one hop away from P(k) that is closest to 1. Keep iterating until all nodes are in P

February 20, 2003 Abhay Parekh: EECS 122 Lecture Dijkstra: Shortest Path P(2)={1,2} D(1,2)= P(3)={1,2,5} D(1,5)= P(4)={1,2,3,5,6} D(1,3)=3 D(1,6)=

February 20, 2003 Abhay Parekh: EECS 122 Lecture Dijkstra: Forwarding Table OutgoingCost At node 5

February 20, 2003 Abhay Parekh: EECS 122 Lecture Distance Vector Protocols Communicate current distance estimates of node to every other node  This is called its distance vector: D i = (D(i,1),D(i,2),…,D(i,n))  Initially, assume that all distance estimates are c(i,j) The nodes do not need to learn the entire topology  Just the distance estimates (vectors) of their neighbors Periodically each node sends its distance vector to all of its neighbors At node 1: D 1 : (0,1, ∞, ∞, ∞,4) Neighbor estimates 2: (1,0, ∞, ∞,∞,∞) 6: (4, ∞,∞,∞,∞,0) At node 6: D 6 : (4, ∞,∞,∞,1,0) Neighbor estimates 1: (0, ∞,∞,∞,∞,4) 5: ( ∞,∞,∞,∞,0,1)

February 20, 2003 Abhay Parekh: EECS 122 Lecture Distance Vector Protocols Upon receiving a more recent distance vector from its neighbors, a node, i, stores it and revises D i : New D(i,d):  The total cost to send it via neighbor j is the sum of The link cost c(i,j) The stored estimate to reach d from j  Pick the lowest sum over all the neighbors  D(i,d) = min jεN(i) {c(i,j) + D(j,d)} Old Info: DV: (4, ∞,∞,∞, 1,0) Neighbor estimates: 1: (0, ∞,∞,∞,∞,4) 5: ( ∞,∞,∞,∞,0,1) Revised: DV: (4,2,2,5,1,0) Neighbor estimates: 1: (0,1, ∞,∞, ∞,4) 5: (∞,1,1,4,0,1) Node 6 receives (0,1,∞, ∞,∞,∞,4) from 1 (∞,1,1,4,0,1) from 5 Send all packets to 2 via 1.

February 20, 2003 Abhay Parekh: EECS 122 Lecture Distance Vector Protocols Forwarding Table at Estimates DV: (3,2,2,4,1,0) Neighbor estimates: 1: (0,1,3,5,2,3) 5: (2,1,1,3,0,1) NodeCost

February 20, 2003 Abhay Parekh: EECS 122 Lecture Why does this compute shortest paths? Suppose in every tick each node sends its distance vector. Assume that initial distances are ∞ At time h, node i has as an estimate of the shortest path to node j that has <= h+1 hops! D h+1 (i,j) = min kεN(i) {D h (k) + c(i,k)}

February 20, 2003 Abhay Parekh: EECS 122 Lecture Counting to Infinity ABC 0 12 ABC 0 34 ABC 0 56 Ping-Pong to Eternity All links cost 1

February 20, 2003 Abhay Parekh: EECS 122 Lecture Bad News Travels Slowly… M 1 D(2,1)=2, D(3,1)=1, D(4,1)=2

February 20, 2003 Abhay Parekh: EECS 122 Lecture Bad News Travels Slowly… M 1 Node 2 takes about M Iterations to figure out that D(2,1)=M Fundamental Cause: After a network change, think of the network protocol running from time 0. The initial conditions are arbitrary… Tricks exist to get around these problems but not fool proof

February 20, 2003 Abhay Parekh: EECS 122 Lecture Asynchronous Bellman Ford In general, nodes are using different and possibly inconsistent estimates If no link changes after some time t, the algorithm will eventually converge to the shortest path No synchronization required at all…

February 20, 2003 Abhay Parekh: EECS 122 Lecture Oscillations Link costs must reflect link speed AND congestion Under both LSP and DV routing occurs over a tree  The costs of the links of this tree will increase The other links will not be congested  Their costs will drop Routing protocol will shift traffic and create a new tree This process of shifting and reshifting can be severe Way out: Change congestion costs slowly (exponential averaging) – Route dampening

February 20, 2003 Abhay Parekh: EECS 122 Lecture Link State vs. Distance Vector No clear winner LS is robust since it each node computes its own routes independently  Suffers from the weaknesses of the topology update protocol. Inconsistency etc.  Excellent choice for a well engineered network within one administrative domain  E. g. OSPF DV works well when the network is large since it requires no synchronization and has a trivial topology update algorithm  Suffers from convergence delays  Very simple to implement at each node  Excellent choice for large networks  E.g. RIP