1 / 39

Intradomain Routing EECS 122: Lecture 10

Routing is the core function of a network that ensures information accepted for transfer at a source node is delivered to the correct set of destination nodes at reasonable levels of performance. This lecture discusses different types of routing protocols and their sub-functions.

barbras
Download Presentation

Intradomain Routing EECS 122: Lecture 10

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


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

  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. 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 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 Abhay Parekh: EECS 122 Lecture 10

  5. 5 7 4 8 6 11 2 10 3 1 13 12 A Graph Model • Nodes are Routers/Hosts • Edges are undirected Abhay Parekh: EECS 122 Lecture 10

  6. Walks A Walk from 1 to 11 Cycle 4-8-7-5-4 5 7 4 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  7. Paths A Path is a Walk with no cycles Routes are Paths 5 7 4 There are 24 paths from 1 to 11 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  8. 2 8 5 7 4 1 2 2 8 12 6 15 2 2 11 2 2 10 3 2 12 7 11 1 3 1 13 12 12 2 Routes A Path is a Walk with no cycles Routes are Paths Edges have weights There are 24 paths from 1 to 11 Abhay Parekh: EECS 122 Lecture 10

  9. 2 8 1 2 2 12 15 2 2 2 3 2 12 7 11 1 12 2 Routing A Path is a Walk with no cycles Routes are Paths 5 7 Edges have weights 4 There are 24 paths from 1 to 11 8 Select the shortest path route Many ways to do this 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  10. 1 A B C D 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 1 1 A B Nothing admitted E E C F F D Abhay Parekh: EECS 122 Lecture 10

  11. 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 Abhay Parekh: EECS 122 Lecture 10

  12. The internet has many Administrative Domains B 5 7 4 8 6 11 2 10 3 1 13 12 C A Abhay Parekh: EECS 122 Lecture 10

  13. Border Routers B 5 7 4 RIP 4 8 6 6 11 2 2 10 OSPF BGP 3 13 3 1 13 12 C IGRP A Abhay Parekh: EECS 122 Lecture 10

  14. Hierarchical Routing 4 4 B 6 BGP 6 B 5 7 IntraDomain 2 InterDomain 2 4 RIP 8 6 3 13 3 13 11 2 10 OSPF IntraDomain IntraDomain 3 1 13 12 IGRP C A Abhay Parekh: EECS 122 Lecture 10

  15. 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 Abhay Parekh: EECS 122 Lecture 10

  16. 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 Abhay Parekh: EECS 122 Lecture 10

  17. 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 Abhay Parekh: EECS 122 Lecture 10

  18. Link State Protocols • Every node learns the topology of the network • Flooding of Link State Packets (LSP) • An efficient shortest path algorithm computes routes to every other node • Node updates Forwarding Table Abhay Parekh: EECS 122 Lecture 10

  19. Source Sequence Number Age List of Neighbors 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 Abhay Parekh: EECS 122 Lecture 10

  20. Example Network 5 7 4 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  21. Example Network 5 7 4 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  22. Example Network 5 7 4 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  23. Example Network 5 7 4 8 6 11 2 10 3 1 13 12 Abhay Parekh: EECS 122 Lecture 10

  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… Abhay K. Parekh: Topics in Routing

  25. 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 Abhay Parekh: EECS 122 Lecture 10

  26. 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 3 2 1 3 2 1 1 4 1 4 4 6 5 1 1 Abhay Parekh: EECS 122 Lecture 10

  27. Dijkstra: Shortest Path • 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 • This node cannot be in P(k) • 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 P(2)={1,2} 3 D(1,5)=2 D(1,6,5)=5 2 1 3 2 1 1 4 1 4 4 6 5 1 1 Abhay Parekh: EECS 122 Lecture 10

  28. 2 1 3 2 1 1 4 1 4 4 6 1 5 1 P(3)={1,2,5} D(1,5)=2 P(4)={1,2,3,5,6} D(1,3)=3 D(1,6)=3 P(2)={1,2} D(1,2)=1 1 1 3 1 4 3 2 2 2 3 3 3 6 1 1 4 1 4 5 6 1 5 6 5 1 6 5 1 3 2 4 2 3 2 Dijkstra: Shortest Path Abhay Parekh: EECS 122 Lecture 10

  29. Dijkstra: Forwarding Table At node 5 3 2 1 3 2 1 1 4 1 4 4 6 5 1 1 Abhay Parekh: EECS 122 Lecture 10

  30. Distance Vector Protocols • Communicate current distance estimates of node to every other node • This is called its distance vector: Di = (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 3 2 1 3 2 1 1 4 1 4 4 6 5 1 1 At node 1: D1: (0,1,∞,∞, ∞,4) Neighbor estimates 2: (1,0,∞,∞,∞,∞) 6: (4,∞,∞,∞,∞,0) At node 6: D6: (4,∞,∞,∞,1,0) Neighbor estimates 1: (0,∞,∞,∞,∞,4) 5: (∞,∞,∞,∞,0,1) Abhay Parekh: EECS 122 Lecture 10

  31. Distance Vector Protocols • Upon receiving a more recent distance vector from its neighbors, a node, i, stores it and revises Di: • 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) = minjεN(i) {c(i,j) + D(j,d)} 3 2 1 3 2 1 1 4 1 4 4 6 1 5 1 Node 6 receives (0,1,∞, ∞,∞,∞,4) from 1 (∞,1,1,4,0,1) from 5 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) Send all packets to 2 via 1. Abhay Parekh: EECS 122 Lecture 10

  32. Distance Vector Protocols • Forwarding Table at 6 3 2 1 3 2 Estimates DV: (3,2,2,4,1,0) Neighbor estimates: 1: (0,1,3,5,2,3) 5: (2,1,1,3,0,1) 1 1 4 1 4 4 6 5 1 1 Abhay Parekh: EECS 122 Lecture 10

  33. 3 2 1 3 2 1 1 4 1 4 4 6 5 1 1 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! • Dh+1(i,j) = minkεN(i) {Dh(k) + c(i,k)} 1 1 1 1 3 4 3 2 2 2 6 2 3 3 3 1 1 1 4 1 4 5 6 6 5 6 5 6 5 4 2 3 2 4 3 2 Abhay Parekh: EECS 122 Lecture 10

  34. A B C 2 1 0 Counting to Infinity All links cost 1 A B C 4 3 0 A B C 6 5 0 Ping-Pong to Eternity Abhay Parekh: EECS 122 Lecture 10

  35. Bad News Travels Slowly… 1 4 3 1 1 1 2 M 1 D(2,1)=2, D(3,1)=1, D(4,1)=2 Abhay Parekh: EECS 122 Lecture 10

  36. Bad News Travels Slowly… 1 4 3 1 Node 2 takes about M Iterations to figure out that D(2,1)=M 1 1 2 M 1 • 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 Abhay Parekh: EECS 122 Lecture 10

  37. 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… Abhay Parekh: EECS 122 Lecture 10

  38. 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 Abhay Parekh: EECS 122 Lecture 10

  39. 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 Link State vs. Distance VectorNo clear winner Abhay Parekh: EECS 122 Lecture 10

More Related