Link-State Routing Reading: Sections 4.2 and 4.3.4 COS 461: Computer Networks Spring 2011 Mike Freedman

Slides:



Advertisements
Similar presentations
Distance-Vector and Path-Vector Routing Sections , 4.3.2, COS 461: Computer Networks Spring 2011 Mike Freedman
Advertisements

1 Dijkstra’s Shortest Path Algorithm Gordon College.
CSE331: Introduction to Networks and Security Lecture 9 Fall 2002.
Fundamentals of Computer Networks ECE 478/578 Lecture #16: Routing Instructor: Loukas Lazos Dept of Electrical and Computer Engineering University of Arizona.
1 Relates to Lab 4. This module covers link state routing and the Open Shortest Path First (OSPF) routing protocol. Dynamic Routing Protocols II OSPF.
Link-State Routing Reading: Sections 4.2 and COS 461: Computer Networks Spring 2010 (MW 3:00-4:20 in COS 105) Michael Freedman
1 EE 122: Shortest Path Routing Ion Stoica TAs: Junda Liu, DK Moon, David Zats (Materials with thanks to Vern.
1 Spring Semester 2007, Dept. of Computer Science, Technion Internet Networking recitation #5 Mobile Ad-Hoc Networks TBRPF.
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.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 21 Introduction to Computer Networks.
Network Layer4-1 Chapter 4: Network Layer r 4. 1 Introduction r 4.2 Virtual circuit and datagram networks r 4.5 Routing algorithms m Link state m Distance.
EE 122: Intra-domain routing Ion Stoica September 30, 2002 (* this presentation is based on the on-line slides of J. Kurose & K. Rose)
Intradomain Routing Jennifer Rexford Advanced Computer Networks Tuesdays/Thursdays 1:30pm-2:50pm.
Delivery, Forwarding and
Routing Algorithms (Ch5 of Computer Network by A. Tanenbaum)
Link State Routing Protocol W.lilakiatsakun. Introduction (1) Link-state routing protocols are also known as shortest path first protocols and built around.
© 2007 Cisco Systems, Inc. All rights reserved.Cisco Public ITE PC v4.0 Chapter 1 1 Link-State Routing Protocols Routing Protocols and Concepts – Chapter.
1 CS 4396 Computer Networks Lab Dynamic Routing Protocols - II OSPF.
Lecture Week 10 Link-State Routing Protocols. Objectives Describe the basic features & concepts of link-state routing protocols. List the benefits and.
1 Computer Communication & Networks Lecture 22 Network Layer: Delivery, Forwarding, Routing (contd.)
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.
Packet-Switching Networks Routing in Packet Networks.
Link-state routing  each node knows network topology and cost of each link  quasi-centralized: each router periodically broadcasts costs of attached.
M.Menelaou CCNA2 ROUTING. M.Menelaou ROUTING Routing is the process that a router uses to forward packets toward the destination network. A router makes.
© 2007 Cisco Systems, Inc. All rights reserved.Cisco Public 1 Version 4.0 Link-State Routing Protocols Routing Protocols and Concepts – Chapter 10.
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.
Intradomain Routing What is Routing? A famous quotation from RFC 791 “A name indicates what we seek. An address indicates where it is. A route indicates.
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.
Routing 2 CS457 Fall 2010.
1 More Routing EE122 Fall 2012 Scott Shenker Materials with thanks to Jennifer Rexford, Ion Stoica, Vern Paxson and.
Overview of Internet Routing (I) Fall 2004 CS644 Advanced Topics in Networking Sue B. Moon Division of Computer Science Dept. of EECS KAIST.
Cisco Systems Networking Academy S2 C 11 Routing Basics.
1 Computer Communication & Networks Lecture 21 Network Layer: Delivery, Forwarding, Routing Waleed.
Data Communications and Computer Networks Chapter 4 CS 3830 Lecture 20 Omar Meqdadi Department of Computer Science and Software Engineering University.
Internet Routing r Routing algorithms m Link state m Distance Vector m Hierarchical routing r Routing protocols m RIP m OSPF m BGP.
Transport Layer 3-1 Chapter 4 Network Layer Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley Chapter4_3.
Routing Algorithms and IP Addressing Routing Algorithms must be ▪ Correctness ▪ Simplicity ▪ Robustness ▪ Stability ▪ Fairness ▪ Optimality.
Routing Protocols Brandon Wagner.
Spring 2000CS 4611 Routing Outline Algorithms Scalability.
© 2007 Cisco Systems, Inc. All rights reserved.Cisco Public 1 Version 4.0 Link-State Routing Protocols Routing Protocols and Concepts – Chapter 10.
4: Network Layer4-1 Chapter 4: Network Layer Last time: r Chapter Goals m Understand network layer principles and Internet implementation r Started routing.
Distance Vector and Link State Routing Pragyaditya Das.
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.
IP tutorial - #2 Routing KAIST Dept. of CS NC Lab.
1 Relates to Lab 4. This module covers link state routing and the Open Shortest Path First (OSPF) routing protocol. Dynamic Routing Protocols II OSPF.
+ Dynamic Routing Protocols 2 nd semester
Network Layer4-1 Chapter 4: Network Layer 4. 1 Introduction 4.2 Virtual circuit and datagram networks 4.3 What’s inside a router 4.4 IP: Internet Protocol.
The network layer: routing
Instructor Materials Chapter 5: Dynamic Routing
Routing Jennifer Rexford.
CS 457 – Lecture 12 Routing Spring 2012.
Network Layer Introduction Datagram networks IP: Internet Protocol
Intra-Domain Routing Jacob Strauss September 14, 2006.
Chapter 5: Dynamic Routing
Fundamentals of Computer Networks ECE 478/578
Chapter 5: Dynamic Routing
Routing in Packet Networks Shortest Path Routing
Road Map I. Introduction II. IP Protocols III. Transport Layer
CS 3700 Networks and Distributed Systems
CS 640: Introduction to Computer Networks
Dynamic Routing and OSPF
COS 561: Advanced Computer Networks
CS4470 Computer Networking Protocols
CS 3700 Networks and Distributed Systems
COS 561: Advanced Computer Networks
COS 461: Computer Networks
Chapter 4: Network Layer
EE 122: Intra-domain routing: Link State
Control-Data Plane Separation
Presentation transcript:

Link-State Routing Reading: Sections 4.2 and COS 461: Computer Networks Spring 2011 Mike Freedman 1

Goals of Today’s Lecture Inside a router – Control plane: routing protocols – Data plane: packet forwarding Path selection – Minimum-hop and shortest-path routing – Dijkstra’s algorithm Topology change – Using beacons to detect topology changes – Propagating topology information Routing protocol: Open Shortest Path First (OSPF) 2

What is Routing? A famous quotation from RFC 791 “A name indicates what we seek. An address indicates where it is. A route indicates how we get there.” -- Jon Postel 3

Routing vs. Forwarding Routing: control plane – Computing paths the packets will follow – Routers talking amongst themselves – Individual router creating a forwarding table Forwarding: data plane – Directing a data packet to an outgoing link – Individual router using a forwarding table 4

Data and Control Planes 5 Switching Fabric Processor Line card data plane control plane

Where do Forwarding Tables Come From? Routers have forwarding tables – Map IP prefix to outgoing link(s) Entries can be statically configured – E.g., “map /24 to Serial0/0.1” But, this doesn’t adapt – To failures – To new equipment – To the need to balance load That is where routing protocols come in 6

Recall the Internet layering model 7 HTTP TCP IP Ethernet interface HTTP TCP IP Ethernet interface IP Ethernet interface Ethernet interface SONET interface SONET interface host router HTTP message TCP segment IP packet

Recall the Internet layering model 8 HTTP TCP HTTP TCP host CPU Switching Fabric IP CPU Switching Fabric Data Plane: Forward along 1 route/path Control Plane: Announce all possible routes Pick best route Install chosen route IP

Computing Paths Between Routers Routers need to know two things – Which router to use to reach a destination prefix – Which outgoing interface to use to reach that router Today’s class: how routers reach each other – How u knows how to forward packets toward z /24 Interface along the path to z u z Router z that can reach destination

Computing the Shortest Paths Assuming you already know the topology 10

Shortest-Path Routing Path-selection model – Destination-based – Load-insensitive (e.g., static link weights) – Minimum hop count or sum of link weights

Shortest-Path Problem Given: network topology with link costs – c(x,y): link cost from node x to node y – Infinity if x and y are not direct neighbors Compute: least-cost paths to all nodes – From a given source u to all other nodes – p(v): predecessor node along path from source to v u v p(v)

Dijkstra’s Shortest-Path Algorithm Iterative algorithm – After k iterations, know least-cost path to k nodes S: nodes whose least-cost path definitively known – Initially, S = {u} where u is the source node – Add one node to S in each iteration D(v): current cost of path from source to node v – Initially, D(v) = c(u,v) for all nodes v adjacent to u – … and D(v) = ∞ for all other nodes v – Continually update D(v) as shorter paths are learned 13

Dijsktra’s Algorithm 14 1 Initialization: 2 S = {u} 3 for all nodes v 4 if (v is adjacent to u) 5 D(v) = c(u,v) 6 else D(v) = ∞ 7 8 Loop: Do 9 find w not in S with the smallest D(w) 10 add w to S 11 update D(v) for all v adjacent to w and not in S: 12 D(v) = min{D(v), D(w) + c(w,v)} 13 until all nodes in S S:Least cost path known D(v):Known shortest cost from source to v C(w,v): Known cost from w to v S:Least cost path known D(v):Known shortest cost from source to v C(w,v): Known cost from w to v

Dijkstra’s Algorithm Example

Dijkstra’s Algorithm Example Loop: Do find w not in S with the smallest D(w) add w to S forall v adj to w && not in S: D(v) = min{ D(v), D(w) + c(w,v) } until all nodes in S Loop: Do find w not in S with the smallest D(w) add w to S forall v adj to w && not in S: D(v) = min{ D(v), D(w) + c(w,v) } until all nodes in S

Dijkstra’s Algorithm Example

Shortest-Path Tree Shortest-path tree from u Forwarding table at u u v w x y z s t v(u,v) w(u,w) x y(u,v) z link s(u,w) t

Learning the Topology By the routers talk amongst themselves 19

Link-State Routing Each router keeps track of its incident links – Whether the link is up or down – The cost on the link Each router broadcasts the link state – To give every router a complete view of the graph Each router runs Dijkstra’s algorithm – To compute the shortest paths – … and construct the forwarding table Example protocols – Open Shortest Path First (OSPF) – Intermediate System – Intermediate System (IS-IS) 20

Detecting Topology Changes Beaconing – Periodic “hello” messages in both directions – Detect a failure after a few missed “hellos” Performance trade-offs – Detection speed – Overhead on link bandwidth and CPU – Likelihood of false detection 21 “hello”

Broadcasting the Link State Flooding – Node sends link-state information out its links – And then the next node sends out all of its links – … except the one(s) where the information arrived 22 X A CBD (a) XA C BD (b) X A CB D (c) XA CBD (d)

Broadcasting the Link State Reliable flooding – Ensure all nodes receive link-state information – … and that they use the latest version Challenges – Packet loss – Out-of-order arrival Solutions – Acknowledgments and retransmissions – Sequence numbers – Time-to-live for each packet 23

When to Initiate Flooding Topology change – Link or node failure – Link or node recovery Configuration change – Link cost change Periodically – Refresh the link-state information – Typically (say) 30 minutes – Corrects for possible corruption of the data 24

When the Routers Disagree (during transient periods) 25

Convergence Getting consistent routing information to all nodes – E.g., all nodes having the same link-state database Consistent forwarding after convergence – All nodes have the same link-state database – All nodes forward packets on shortest paths – The next router on the path forwards to the next hop

Transient Disruptions Detection delay – A node does not detect a failed link immediately – … and forwards data packets into a “blackhole” – Depends on timeout for detecting lost hellos ✗

Transient Disruptions Inconsistent link-state database – Some routers know about failure before others – The shortest paths are no longer consistent – Can cause transient forwarding loops

Convergence Delay Sources of convergence delay – Detection latency – Flooding of link-state information – Shortest-path computation – Creating the forwarding table Performance during convergence period – Lost packets due to blackholes and TTL expiry – Looping packets consuming resources – Out-of-order packets reaching the destination Very bad for VoIP, online gaming, and video 29

Reducing Convergence Delay Faster detection – Smaller hello timers – Link-layer technologies that can detect failures Faster flooding – Flooding immediately – Sending link-state packets with high-priority Faster computation – Faster processors on the routers – Incremental Dijkstra’s algorithm Faster forwarding-table update – Data structures supporting incremental updates 30

Scaling Link-State Routing Overhead of link-state routing – Flooding link-state packets throughout the network – Running Dijkstra’s shortest-path algorithm Introducing hierarchy through “areas” 31 Area 0 Area 1 Area 2 Area 3 Area 4 area border router

Conclusions Routing is a distributed algorithm – React to changes in the topology – Compute the paths through the network Shortest-path link state routing – Flood link weights throughout the network – Compute shortest paths as a sum of link weights – Forward packets on next hop in the shortest path Convergence process – Changing from one topology to another – Transient periods of inconsistency across routers 32