Lesson 5-2: Open Shortest Path First Protocol

Similar documents
Chapter 22 Network Layer: Delivery, Forwarding, and Routing 22.1

Module 8. Routing. Version 2 ECE, IIT Kharagpur

C13b: Routing Problem and Algorithms

Fairness Example: high priority for nearby stations Optimality Efficiency overhead

How Routing Algorithms Work

ITEC310 Computer Networks II

CSCD 330 Network Programming Spring 2018

CSCD 330 Network Programming Spring 2017

ICS 351: Today's plan. distance-vector routing game link-state routing OSPF

THE OSI MODEL. Application Presentation Session Transport Network Data-Link Physical. OSI Model. Chapter 1 Review.

5.2 Routing Algorithms

Why dynamic route? (1)

Network Layer: Routing

BLM6196 COMPUTER NETWORKS AND COMMUNICATION PROTOCOLS

Computer Networks. Routing Algorithms

Telecommunication Protocols Laboratory Course. Lecture 3

Table of Contents. Cisco Introduction to EIGRP

Computer Networks. Routing

ETSF05/ETSF10 Internet Protocols. Routing on the Internet

Computer Networks 1 (Mạng Máy Tính 1) Lectured by: Dr. Phạm Trần Vũ

Routing Protocols. The routers in an internet are responsible for receiving and. forwarding IP datagrams through the interconnected set of

EEC-684/584 Computer Networks

ICS 351: Today's plan. OSPF BGP Routing in general

William Stallings Data and Computer Communications 7 th Edition. Chapter 12 Routing

Alternate Routing Diagram

CCNA 3 (v v6.0) Chapter 5 Exam Answers % Full

Routing Basics. What is Routing? Routing Components. Path Determination CHAPTER

ETSF05/ETSF10 Internet Protocols Routing on the Internet

Routing Algorithms McGraw-Hill The McGraw-Hill Companies, Inc., 2001

Routing with a distance vector protocol - EIGRP

CHAPTER 4: ROUTING DYNAMIC. Routing & Switching

We will discuss about three different static routing algorithms 1. Shortest Path Routing 2. Flooding 3. Flow Based Routing

Course Routing Classification Properties Routing Protocols 1/39

Chapter 7: Routing Dynamically. Routing & Switching

Youki Kadobayashi NAIST

Helsinki University of Technology Telecommunications Laboratory. OSPF Routing Protocol Licenciate course seminar paper

Distance Vector Routing Protocols

Introduction to IP Routing. Geoff Huston

Lecture 9. Reminder: Homework 3, Programming Project 2 due today. Questions? Thursday, September 22 CS 475 Networks - Lecture 9 1

COM-208: Computer Networks - Homework 6

Inter-AS routing. Computer Networking: A Top Down Approach 6 th edition Jim Kurose, Keith Ross Addison-Wesley

Network Layer, Part 2 Routing. Terminology

Youki Kadobayashi NAIST

Top-Down Network Design

Two types of routing protocols are used in internetworks: interior gateway protocols (IGPs) and exterior gateway protocols (EGPs).

Routing Algorithms. CS158a Chris Pollett Apr 4, 2007.

Routing. Advanced Computer Networks: Routing 1

Top-Down Network Design, Ch. 7: Selecting Switching and Routing Protocols. Top-Down Network Design. Selecting Switching and Routing Protocols

Redes de Computadores. Shortest Paths in Networks

Homework 3 Discussion

Exam Questions 4A0-101

Unit 3: Dynamic Routing

IP Routing. Bharat S. Chaudhari International Institute of Information Technology Pune, India

TDC 363 Introduction to LANs

QoS Routing By Ad-Hoc on Demand Vector Routing Protocol for MANET

Routing Protocol comparison

Overview. Information About Layer 3 Unicast Routing. Send document comments to CHAPTER

VI. ROUTING. - "routing protocol" nodes exchange information to ensure consistent understanding of paths

Topology. Youki Kadobayashi NAIST. Outline. Routing system: its function. Gateway Model Revisited. Routing system: its structure

Open Shortest Path First (OSPF)

II. Principles of Computer Communications Network and Transport Layer

FINAL EXAM - SLOT 2 TCP/IP NETWORKING Duration: 90 min. With Solutions

Finish Network Layer Start Transport Layer. CS158a Chris Pollett Apr 25, 2007.

In this edition of HowStuffWorks, we'll find out precisely what information is used by routers in determining where to send a packet.

Unicast Routing. Information About Layer 3 Unicast Routing CHAPTER

Basic Idea. Routing. Example. Routing by the Network

9.1. Routing Protocols

2008 NDP Lectures 7 th Semester

CSCI 466 Midterm Networks Fall 2011

CHAPTER 9: PACKET SWITCHING N/W & CONGESTION CONTROL

Routing by the Network

Configuring OSPF. Cisco s OSPF Implementation

BTEC Level 3 Extended Diploma

Alcatel-lucent EXAM - 4A Alcatel-Lucent Interior Routing Protocols and High Availability. Buy Full Product.

UNIT 2 ROUTING ALGORITHMS

Chapter 12. Routing and Routing Protocols 12-1

FXT - Foundations of Telematic Networks

User Datagram Protocol (UDP):

Routing Unicast routing protocols

TCPIP Protocol Suite & Utilities. Revision no.: PPT/2K403/02

Chapter 2 - Part 1. The TCP/IP Protocol: The Language of the Internet

Linux System Administration

ICS 451: Today's plan. Network Layer Protocols: virtual circuits Static Routing Distance-Vector Routing

Routing Protocols of IGP. Koji OKAMURA Kyushu University, Japan

Unicast Routing in Mobile Ad Hoc Networks. Dr. Ashikur Rahman CSE 6811: Wireless Ad hoc Networks

Youki Kadobayashi NAIST

Chapter 6 Reading Organizer

Routing Protocols. Autonomous System (AS)

Routing. Jens A Andersson Communication Systems

Youki Kadobayashi NAIST

CSE 123: Computer Networks

Intra-domain Routing

NetWare Link-Services Protocol

Chapter 4 Network Layer

CS 5114 Network Programming Languages Control Plane. Nate Foster Cornell University Spring 2013

Network Routing Protocol using Genetic Algorithms

Performance Analysis of Routing Techniques in Networks

ECE 653: Computer Networks Mid Term Exam all

REDDIG II Computer Networking Training

EECS 122, Lecture 16. Link Costs and Metrics. Traffic-Sensitive Metrics. Traffic-Sensitive Metrics. Static Cost Metrics.

Transcription:

Unit 5: Intradomain and Interdomain Routing Protocols Lesson 5-2: Open Shortest Path First Protocol At a Glance The Open Shortest Path First (OSPF) protocol was developed to answer problems that RIP could not resolve. By the mid-1980 s, RIP was unable to adequately serve large differentiated internetworks. OSPF is based on Dijkstra s algorithm, named for its creator E.W. Dijkstra, and can operate in large hierarchical networks. What You Will Learn After completing this lesson, you will be able to do the following: Briefly compare distance-vector and link-state protocols. Diagram the three OSPF phases. Describe the advantages of link-state routing. Tech Talk Dijkstra s Algorithm A routing algorithm created by E.W. Dijkstra that calculates the shortest path for delivery of a packet across a network. Hello Packet Messages broadcast across a network by a node to itself to the other nodes and to indicate that the node is still operational Interdomain Routing Protocols Routing protocols that operate within and between domains. Link-state Update Message Message issued by an OSPF router informing neighboring routers of a path change in the network. OSPF's Flooding Protocol The process of forwarding update messages across the network to all the OSPF routers. ST0025804A 203

Lesson 5-2: Open Shortest Path First Protocol Link-State Routing Link-state routing differs from distance-vector routing in that each router in the network maintains a complete model of the entire network. Where distance-vector protocols keep only two pieces of information about a network, its distance and the next hop towards its destination, link-state protocols keep information about every single node in the network, and the states of every link between them. Using this information they can compute the shortest path to any destination, and from that they can infer a next hop. Instead of distributing the selection of the shortest path between two points across all the routers in the network, link-state protocols force each router to compute the shortest path between itself and every other node. From experience, the network managers know that link-state protocols scale much better than their distance-vector protocols. While RIP may still be the most popular routing protocol on local networks, link-state protocols are used more often in larger networks. The most common link-state protocol is the Open Shortest Path First (OSPF) protocol. 204 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Open Shortest Path First Protocol As stated previously, the Open Shortest Path First (OSPF) protocol is the most common link-state protocol. It is a member of the TCP/IP family. The OSPF algorithm has three phases. The first phase is finding neighbors. To do this, OSPF sends a "Hello" packet to each neighbor. Among the things in this packet is a list of neighbors from which the sender has recently received a Hello. In the illustration below, for instance, Router B is turned on for the first time. It sends a Hello packet to Router A. Router A Router C Hello B 2nd Step Hello Router B 1st Step Router D Hello Packets Are Exchanged Shortly after that, Router A will, in the normal course of events, send a Hello to Router B, which lists Router B as a neighbor from whom it has heard recently. Router B is then assured that it has an adjacency to Router A. The routers continue to send periodic Hello packets to their neighbors, to verify the states of their links. ST0025804A 205

Lesson 5-2: Open Shortest Path First Protocol In the second phase of the OSPF process, a new router obtains a complete copy of its neighbor's link-state database. This is a complex and careful process that goes to considerable length to be certain that the new router has an exact copy of the existing routers database. New Router Received Complete Link-State Database Router A Router C Router B Router D New Router Router E Router D s Link-State Database 206 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols The third and final phase of the OSPF protocol is the normal state for a running OSPF router. The fully initialized router sends and accepts updated describing changes in the states of network links. This process is accomplished with OSPF's "flooding" protocol. Flooding Router A Router C Router B Router D Updates (Receives) (Sends) Updates Router E Router D s Link-State Database ST0025804A 207

Lesson 5-2: Open Shortest Path First Protocol Suppose the link between Router A and Router B fails in the network previously illustrated. Router A and Router B will both notice the failure and immediately broadcast Link-state Update messages to Routers C and D, respectively. These messages will indicate a change in a particular record in the shared database. Since Routers A and B have identical databases, they will both identify the same record. Link-state Update Messages 2nd Router A Updates Router C 1st Break 2nd Router B Updates Router D Router E Routers C and D, upon receiving the message will compare the serial number for the newly arrived record to the serial number for the existing record in their databases. Based on this comparison they will take one of three actions: If the new serial number is the same as the old, they will discard the message If the new serial number is less than the old, they will discard the new message, and send a Link-state update message containing the record from the local database back to the originator. If the new serial number is greater than the old, they update their local databases, and forward the update to all neighbors, except the one from which they received it. 208 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols In the example, then, Router C will forward the update to Router D. Router D will forward to Routers C and E. At that point, since Routers C and D have both already seen the update, they do not forward it further. All routers have now been informed of the failure of the link between Routers A and B. Link-state Update Messages Are Forwarded Router A Router C Router B Updates Updates Router D Updates Router E Router D s Link-State Database ST0025804A 209

Lesson 5-2: Open Shortest Path First Protocol Check Your Understanding Given the scenario in the diagram below, outline how OSPF would update the routers on the network of the conditions in the diagram. What is the most likely path to deliver packets to Router E in this diagram? Router A Router C Router B BREAK!! Router D Router E 210 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Advantages of Link-State Routing The description of the OSPF protocol above is considerably simplified. The document that specifies OSPF is more that 100 pages of fine type, and more that five times the length of the specification for RIP. Why, then, do most large networks use link-state routing, instead of the simpler distancevector protocols? There are three main reasons: Fast convergence Concise, multiple metrics Support for multiple paths Fast Convergence RIP's primary flaw is the amount of time it takes all of the routers in a network to adapt to a change in the network. In general transients particularly affect distance-vector routing protocols because they distribute the computation of new routes across the whole network. It may take several exchanges of information before a group of routers finally agrees on the new topology. In link-state protocols, on the contrary, in the time it takes a packet to cross the network, all routers know exactly what has changed, and has an accurate new database. ST0025804A 211

Lesson 5-2: Open Shortest Path First Protocol Multiple, Concise Metrics Because of the counting-to-infinity problem, it is difficult for a distancevector protocol to support concise metrics. RIP uses only integers from 0 to 16. In a network that is differentiated between four different line speeds, assigning them weights of 1 to 4, the maximum distance between two routers might have to be no more than 3 physical hops. In the diagram below, the distance from Router A to Router F, using the weighted hop counts indicated, is 16. These two routers would be unreachable from each other, using RIP. RIP s Counting to Infinity Router A Router C Router E 4 Router B 3 4 1 Router D 4 4 Router F (Total = 16!) Since link-state protocols specify the exact information about a link, it is possible to include very precise specification of metrics. It is even possible to include several kinds of metrics: delay, reliability, and price. With this information a router can route a packet based on the particular type of service it requests. 212 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Support for Multiple Paths Consider the network shown below. There are two paths, ACDE, and ABDE, of equal cost, from Router A to Router E. Suppose the vast majority of traffic on this network is from Router A to Router E. Using a distance-vector routing protocol, Router A will choose one or the other of those two paths, arbitrarily, and use it for all of the traffic to Router E. For instance, it might choose the path through Router C, and never use the path through Router B. This would waste half of the network's bandwidth from Router A to Router E. Link-state Algorithm Maps the Entire Network Router A 1 Router C 3 Router B 2 4 Router D 1 Router E Since a link-state algorithm has an entire map of the network, it has the information necessary to compute alternative paths. ST0025804A 213

Lesson 5-2: Open Shortest Path First Protocol Try It Out What s My Topology? In this activity you will discover the topology of the network drawn in advance by your teacher. Materials Needed: Topology handout for drawing the network Link-state Routing Table to record node locations Dijkstra's Algorithm Worksheet Teams of three students, each team representing a node Pen/Pencil and Paper Part One: The Game Rules: 1. To start the game, all teams must name their node and take their starting link table to an assigned location. Your teacher will tell you the locations of your neighbors, and when to start. 2. You may send a runner any number of times to any adjacent neighbor and request their link state data (names of their neighbors, their neighbors neighbors, and so on). 3. The runner must return to his/her home site and update their link table with the new information. 4. When you update your table, draw the emerging topology. 5. A team member must be available at your home site to answer requests from other runners. 6. If you arrive at a node when an update is in progress, wait for it to complete before getting the link table. 7. The game is over when all teams have announced to their site administrator (your teacher) that they have discovered the topology and drawn it. 8. Gather together with the rest of the teams. 214 9. Compare your topologies with the other teams and choose the topology that is correct for the network designed by your teacher. ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Part Two: Dijkstra s Algorithm 1. Using the Dijkstra s algorithm worksheet, fill in the routing table for your node according to the rules of the algorithm. Were there problems using the algorithm to map your topology? If so, why? Rubric: Suggested Evaluation Criteria and Weightings Criteria % Your Score Enthusiastic and cooperative participation 50 Correct network topology diagram 25 Correct Dijkstra s algorithm routing table 25 TOTAL 100 Developed by Nancy Ishihara, Blake Meike, Deborah Muscella, and John Zinky for the Connecting Communities Project, TERC. Copyright 1996 by TERC. Reprinted with permission. ST0025804A 215

Lesson 5-2: Open Shortest Path First Protocol What s My Topology? Master Link Table for Node Team Members: Location Neighbor Locations Links: From: (Node Name) To: (Node Name) 216 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols What s My Topology? Runner Link Table Node (name of node visited) has links: From: (Node Name) To: (Node Name) ST0025804A 217

Lesson 5-2: Open Shortest Path First Protocol What s My Topology? Dijkstra s Algorithm For finding the shortest path to all nodes follow these steps: 1. Mark yourself as length 0 2. Look at the length 0 node for length 1 nodes 3. Mark the length 1 nodes 4. Look at length 1 nodes for length 2 nodes 5. Mark the length 2 nodes 6. Look at length 2 nodes for length 3 nodes 7. Mark the length 3 nodes Routing Table for Node: To Toward Length A B C D E F G H 218 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Stretch Yourself Body Routing In this activity you will deliver all the messages to their destinations and return an acknowledgement to the originating node. Materials Needed: Tape Complete routing table for each node (developed in Try It Out) One log/node to record messages sent and received Node signs Message tags Rules to post at node Pen/Pencil and Paper Players: 2 students/node are Nodes All other students are Messages One adult/node One game facilitator to visit nodes and answer questions and facilitate communication. Rules: 1. Use the topology from the Try It Out with the names filled in. 2. All nodes must choose and announce their names. 3. Decide what the destination of your messages will be and fill in the tags with the appropriate information. 4. Messages are not intelligent. They need to follow the instructions of the Nodes. Each node has an equal number of messages. 5. Nodes handle messages as follows: a. If you are the destination of the Message (TO:). Check the RECEIVED box. Cross out TO: and FROM: nodes. Rewrite TO: as FROM: and FROM: as TO: (message is now on its return trip) and return the message to its originator (now TO:) ST0025804A 219

Lesson 5-2: Open Shortest Path First Protocol b. If you are the originator of the Message (you are the original FROM: and RECEIVED is checked), mark it as RECEIVED in your log. This message has been successfully sent and acknowledged and is no longer in play. c. Otherwise, look up the TO: node of the Message in your table and send it Towards the corresponding node. 6. There is only one wire. Messages may not pass each other (congestion). When 2 messages meet going in opposite directions (collisions) the Nodes must decide on a rule to get the Messages where they need to go. 7. To start the game: Messages will be given a FROM: and TO: Node address on their tag and started at the FROM: node. Nodes will be stationed at their nodes. 8. The game is over when all the messages have gotten to their destination and returned. As a team, write a summary of your experiences in this game. What problems occurred? What were the solutions? Relate the game to what you have learned about routing algorithms. How well does the game simulate the algorithms? If you were creating a game, what would you do differently? Rubric: Suggested Evaluation Criteria and Weightings Criteria % Your Score Attentive and cooperative participation 50 Successful delivery of all Messages 25 Insightful summary of experiences and critique of the game TOTAL 100 25 Developed by Nancy Ishihara, Blake Meike, Deborah Muscella, and John Zinky for the Connecting Communities Project, TERC. Copyright 1996 by TERC. Reprinted with permission. 220 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Body Routing Team Members: Message Log for Node Body Routing TO FROM RECEIVED TO: MESSAGE: FROM: REPLY: RECEIVED TO: MESSAGE: FROM: REPLY: RECEIVED ST0025804A 221

Lesson 5-2: Open Shortest Path First Protocol Network Wizards Design Your Own Algorithm A routing algorithm can be calculated using many different metrics (parameters or values). Each algorithm that has been written for routing has been designed on multiple types of metrics. Some algorithms use only one metric; for example, RIP uses hop count, other use multiple metrics. These algorithms did not just appear. They were written by network designers as a means to create ever more efficient routing procedures. In this activity you will discover the topology of the network drawn in advance by your teacher. Materials Needed: Windows 95 PC Internet Connection Any Word Processor (e.g., MS Word) Pen/Pencil and Paper 1. Research other routing algorithms over the Internet and any other source you feel appropriate. Reference at least five resources. 2. Design an algorithm (name it after yourself, of course) that can be used for creating routing tables and assuring efficient delivery of packets across a network. 3. It is entirely possible that your algorithm will have problems, perhaps problems that are not self-evident. Try using your algorithm with a team of students. 4. Write a clear and concise description of your algorithm, including each step. With your description, write a summary of the success of your algorithm based on the trial simulation you conducted with your team. Rubric: Suggested Evaluation Criteria and Weightings Criteria % Your Score Thorough research including five resources 25 Creative algorithm reflecting quality analysis 50 Clear and concise description and critique of algorithm TOTAL 100 25 222 ST0025804A Routing

Unit 5: Intradomain and Interdomain Routing Protocols Summary In this lesson, you learned the following: The comparison between distance-vector and link-state protocols. How to diagram the three OSPF phases. The advantages of link-state routing. Review Questions Name Lesson 5-2: Open Shortest Path First Protocol Part A 1. Compare the basic features of distance-vector and link-state routing protocols. Part B 1. Diagram the three OSPF phases in building a link-state routing table. Part C 1. Describe the advantages of link-state routing. ST0025804A 223

Lesson 5-2: Open Shortest Path First Protocol Scoring Rubric: Suggested Evaluation Criteria and Weightings Criteria % Your Score Part A: Briefly compare distance-vector and link-state protocols 25 Part B: Diagram the three OSPF phases 50 Part C: Describe the advantages of link-state routing TOTAL 100 Try It Out 100 Stretch Yourself 100 Network Wizards 100 FINAL TOTAL 100 25 Resources Comer, D. E. (1995). Internetworking With TCP/IP : Principles, Protocols, and Architecture 3rd edition, Prentice Hall, Upper Saddle River, New Jersey. Perlman, R. (1992). Interconnections: Bridges and Routers, Addison-Wesley Publishing Co.,Reading, MA. Stevens, W. R.(1994). TCP/IP Illustrated, Volume 1: The Protocols, Addison-Wesley Publishing Co., Reading, MA. Tannenbaum, A.S. (1996). Computer Networks, Prentice Hall, Upper Saddle River, New Jersey. 224 ST0025804A Routing