ECE 333: Introduction to Communication Networks Fall 2001

Similar documents
Routing. 4. Mar INF-3190: Switching and Routing

Routing Algorithms. CS158a Chris Pollett Apr 4, 2007.

Routing in packet-switching networks

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

Chapter 12. Routing and Routing Protocols 12-1

William Stallings Data and Computer Communications. Chapter 10 Packet Switching

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

Chapter 5 (Week 9) The Network Layer ANDREW S. TANENBAUM COMPUTER NETWORKS FOURTH EDITION PP BLM431 Computer Networks Dr.

Lecture 4 Wide Area Networks - Routing

Internetworking Part 1

Lecture (08, 09) Routing in Switched Networks

ETSF05/ETSF10 Internet Protocols Routing on the Internet

5.2 Routing Algorithms

Network Layer: Routing

ETSF05/ETSF10 Internet Protocols. Routing on the Internet

Routing in Switched Data Networks

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

Module 8. Routing. Version 2 ECE, IIT Kharagpur

Outline. Routing. Introduction to Wide Area Routing. Classification of Routing Algorithms. Introduction. Broadcasting and Multicasting

(Refer Slide Time: 01:08 to 01:25min)

Fairness Example: high priority for nearby stations Optimality Efficiency overhead

Course 6. Internetworking Routing 1/33

The Open System Interconnect model

Youki Kadobayashi NAIST

ICMP, ARP, RARP, IGMP

Routing. Information Networks p.1/35

C13b: Routing Problem and Algorithms

Internetworking. different kinds of network technologies that can be interconnected by routers and other networking devices to create an internetwork

Intra-domain Routing

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

ECE 435 Network Engineering Lecture 11

Telecommunication Protocols Laboratory Course. Lecture 3

CSE 461 Routing. Routing. Focus: Distance-vector and link-state Shortest path routing Key properties of schemes

Routing, Routing Algorithms & Protocols

CS 457 Networking and the Internet. What is Routing. Forwarding versus Routing 9/27/16. Fall 2016 Indrajit Ray. A famous quotation from RFC 791

Data and Computer Communications. Chapter 12 Routing in Switched Networks

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

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

ECE 333: Introduction to Communication Networks Fall 2001

Alternate Routing Diagram

Course Routing Classification Properties Routing Protocols 1/39

Redes de Computadores. Shortest Paths in Networks

Distance vector and RIP

CHAPTER 9: PACKET SWITCHING N/W & CONGESTION CONTROL

CSCE 463/612 Networks and Distributed Processing Spring 2018

ECE 435 Network Engineering Lecture 11

This Lecture. BUS Computer Facilities Network Management. Switching Network. Simple Switching Network

6.02 Fall 2014! Lecture #21. Failures in routing Routing loops Counting to infinity

Wide area networks: packet switching and congestion

BLM6196 COMPUTER NETWORKS AND COMMUNICATION PROTOCOLS

Routing Strategies. Fixed Routing. Fixed Flooding Random Adaptive

Revision of Previous Lectures

Youki Kadobayashi NAIST

CompSci 356: Computer Network Architectures. Lecture 8: Spanning Tree Algorithm and Basic Internetworking Ch & 3.2. Xiaowei Yang

Routing in a network

What Is CCNA? p. 2 CCNA Exam Philosophy p. 4 What Cisco Says about CCNA p. 4 What We Can Infer from What Cisco States p. 5 Summary of the CCNA Exam

Computer Science 425 Distributed Systems CS 425 / ECE 428. Fall 2013

Youki Kadobayashi NAIST

Distributed Routing. EECS 228 Abhay Parekh

CS118 Discussion Week 7. Taqi

The Network Layer. Network Layer Design Objectives

Computer Networking. Intra-Domain Routing. RIP (Routing Information Protocol) & OSPF (Open Shortest Path First)

Interplay between routing, forwarding

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

Lecture 4. The Network Layer (cont d)

===================================================================== Exercises =====================================================================

Routing. Advanced Computer Networks: Routing 1

Digital Communication Networks

Data & Computer Communication

Principles of Wireless Sensor Networks. Routing, Zigbee, and RPL

Network Layer (Routing)

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

Lecture 12. Introduction to IP Routing. Why introduction? Routing

Network layer: Overview. Network layer functions Routing IP Forwarding

II. Principles of Computer Communications Network and Transport Layer

CSCD 330 Network Programming Spring 2018

CSCD 330 Network Programming Spring 2017

Top-Down Network Design

CEN445 Network Protocols & Algorithms. Network Layer. Prepared by Dr. Mohammed Amer Arafah Summer 2008

Principles of Wireless Sensor Networks

CSEP 561 Routing. David Wetherall

ICS 351: Today's plan. netmask exercises network and subnetwork design dynamic routing RIP distance-vector routing

CSC 401 Data and Computer Communications Networks

Graph Algorithms. Many problems in networks can be modeled as graph problems.

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

Distributed Queue Dual Bus

Lecture 9. Network Layer (cont d) Network Layer 1-1

IP Address Assignment

Computer Networks. Wenzhong Li. Nanjing University

Distance-Vector Routing: Distributed B-F (cont.)

Module 1. Introduction. Version 2, CSE IIT, Kharagpur

Chapter 3 Packet Switching

Data Networks. Lecture 1: Introduction. September 4, 2008

Internetworking Terms. Internet Structure. Internet Structure. Chapter 15&16 Internetworking. Internetwork Structure & Terms

Unit 3: Dynamic Routing

Introduction to Routing

Administrivia CSC458 Lecture 4 Bridging LANs and IP. Last Time. This Time -- Switching (a.k.a. Bridging)

CMPE 150: Introduction to Computer Networks

Copyright 2010, Elsevier Inc. All rights Reserved

EE 122: Intra-domain routing

Transcription:

ECE : Introduction to Communication Networks Fall 00 Lecture : Routing and Addressing I Introduction to Routing/Addressing Lectures 9- described the main components of point-to-point networks, i.e. multiplexed transmission lines and switches or routers. These networks usually have a mesh topology with multiple paths between any two hosts. A routing algorithm determines the specific route that traffic takes through a network. For example, in datagram networks, the routing algorithm determines what information is the routing table at each node in the network. In the next few lectures, we will study problem of routing in more detail. Our focus will mainly be on packet switched data networks. Routing is one of the main functions of the network layer. Network layer protocols, such as routing, involve every node in the subnet. Protocols at lower layers are generally point-to-point, and protocols at higher layers, e.g. the transport layer, are end-to-end. The basic service the network layer provides the transport layer is the delivery of packets from the source to destination. As with the data link layer, the network layer can offer different variation of this service - for example it may be connection-oriented (as in virtual circuit networks) or connectionless. The network layer could try to ensure some level of reliability or guarantee some level of quality. For example, a circuit switched network provides user end-to-end delivery of data at a fixed rate and with known delay.

The network layer in ATM networks (see Lecture ) is called the ATM layer. The ATM layer provides a choice of several different services such as a constant rate, connection-oriented, low delay service and a variable-rate unreliable service. Different services are designed to be suitable for different applications, such as voice, data, etc. In TCP/IP, the IP layer serves as the network layer. It provides a connectionless, unreliable service to the transport layer. In other words, packets are delivered from source to destination but they may not arrive, or if they arrive, they are not guaranteed to be in order. In TCP/IP networks, any additional reliability needed by an application is addressed at the transport layer. A key trade-off between these two approaches is how much intelligence is put in the subnet and how much is put in the hosts. In TCP/IP the decision was to put as much burden on the host as possible; with ATM more burden is placed on the subnet. In either case, routing is addressed at the network layer. Routing We looked at routing when considering bridges and extended LANs in Lecture 9. For transparent bridges, routing was done by forming a spanning tree and sending all packets along this tree. In this case, the routing algorithm is the protocol the bridges use to exchange messages and find a spanning tree. A similar approach can be used in a WAN, but this is generally not a good idea. One reason is that with a spanning tree some links will be unused, while other links will be heavily loaded. In a large network, it is desirable to spread out the load among multiple links to reduce congestion and more efficiently use the network. The main characteristics desired from a routing algorithm include: Correctness - deliver packets to their correct destinations. Robustness - when nodes and/or links fail, the routing algorithm should be able to recover from this. Simplicity - the algorithm should be able to be implemented by many switches in a large network, and not require a large amount of overhead. Given the above characteristics, it would also be desirable to have an algorithm that finds the "best" paths between a source and destination and is "fair" to different sessions. However, concepts like "best" and "fair" can be interpreted in several different ways. 4

Routing Characteristics A variety of different routing algorithms have been proposed and used in networks. These algorithms can be classified in several ways. A routing algorithm is static if it uses predetermined routes that do not change over time. A dynamic routing algorithm bases the route assignment on the current network load, in this case route assignments may change with each session or with each packet. Routing algorithms may be centralized, where routes are calculated at one place and disseminated to all nodes, or distributed, in which case all routers exchange information and calculate routes locally. For example, the spanning tree algorithm used by transparent bridges is a dynamic, distributed algorithm. Most of the algorithms we will consider in the following are also of this type. Flooding A simple approach to routing is flooding. With flooding, upon receiving a packet each node forwards it over all links except the one from which it is received. Thus, every node on the network will eventually receive the packet (including the desired destination). One problem with flooding is how to make sure that packets do not circulate forever. This can be accomplished by several methods including:. Put a sequence number on each packet, and have each switch make sure it does not forward a packet more than once.. Put an age field in the packet header that is decreased every time a packet is forwarded, don t forward any packets once this field reaches zero.. Put an identifier for the links a packet has traversed in the packet header, don t forward a packet over a link more than once. An advantage of flooding is that no routing tables or topological knowledge needed at any switch, and little processing is required at each node. The disadvantage is that much unneeded traffic is generated - every packet will be sent over every link. Two places where flooding is used are () in some ad hoc wireless networks, where nodes are moving around to quickly for any other techniques to work, and () for forwarding control or topological information (e.g. in link state routing discussed later). 6

Shortest path routing Many routing algorithms are variants of shortest path algorithms. In such algorithms, each link is assigned a cost this could represent some quantity of interest such as distance or delay for that link. A shortest path algorithm then attempts to find the route between any pair of nodes that minimizes the sum of the link costs. To visualize such algorithms, consider a graph corresponding to the subnet as shown below. In this graph, the nodes represent routers and the arcs represent links. The number by each link is the cost of the link. In this figure, the shortest path between nodes and is through node 4 and has a total cost of + =. 6 4 7 To build routing tables we would like to find the shortest path from each node to all other nodes. Also, for dynamic routing, link costs will change with time and so may the shortest paths. A method is needed to efficiently calculate shortest paths. Two of the main approaches for calculating shortest paths are:. Distant vector routing - uses distributed Bellman-Ford algorithm.. Link state Routing uses Dijkstra s algorithm. Both of these can be implemented as distributed, dynamic routing algorithms. 8

Distance Vector Routing In distance vector routing, each router must maintain a table (vector) of its best-known distance (cost) to each destination as well as which link to use to get there. Each router is assumed to know the cost of the links that connect it directly to each of its neighbors. Routers then exchange their distance vectors locally, i.e. with their neighbors. They update their distance vectors based on these exchanges. The Bellman-Ford algorithm is used for this updating. In a graph two nodes are called neighbors if there is a link that directly connects them. 9 "Optimality principal" The basic idea behind the Bellman-Ford algorithm is the so-called "optimality principal". This states that if node A is on a shortest path from node I to J, then the segment of the path from A to J is also a shortest path from A to J. In the figure below, assume that the shortest path from I to J is through node A and then node X. Suppose that the optimality principal was not true and that the path A -Y- J is a shorter path from A to J than A -X- J. Then by taking the path from I to A followed by the path A-Y-J, must result in a shorter path from I to J than the path through X. This contradicts the assumption that the original path was the shortest. I X J A Y 0

Bellman-Ford Next we describe the Bellman-Ford algorithm. We describe the algorithm in the context of calculating the shortest path from all nodes in a network to a given destination node. A version of the algorithm would be implemented for each destination. For the given destination, let Dn(j) be the estimated distance from node j to the destination at time n. Let di,j be the distance from node i to j. Basic idea: Each neighbor j of node i sends Dn(i) to node i, then node i updates its estimate according to: D i) min ( d D ( )) n ( i, j n j j N(i) The quantities on the right-hand side of this expression are the distances to each neighbor, j plus the minimum distance from j to the destination. The port towards the neighbor j that attains the minimum is chosen as the port towards the destination. (Ties can be broken using any rule.) The algorithm is initialized in the following manner: Set D0(i) = for all nodes i, except the destination, d. Set D0(d) =0. From this initialization, it can be shown that above algorithm will terminate (no more changes will occur) in at most N steps where N is the number of nodes. (Provided there are no link failures, see count-to-infinity problem below) At termination each node knows the shortest path to the destination. The Bellman Ford algorithm can be shown to work asynchronously, where each node sends out its distance vector at arbitrary times.

Bellman - Ford Example 6 4 An example of the Bellman-Ford algorithm for the above network is given. Assume the destination, d = 6, so D 0 (6)=0 and D 0 (i)=, for all i 6. We consider a synchronous version of the algorithm, where all nodes send out there updates to all their neighbors at the same time. After the first cycle of updates, all nodes receive costs D 0 (i) from their neighbors. The only ones that are going to have non-infinite cost are the nodes link away from d=6. These are nodes and, they will receive D0(6) =0. Thus at node we have: D () min( 0,, ) and the next node on the shortest path for node becomes 6. Similarly, D () will be updated to. After the second cycle of updates, node will receive non-infinite costs from nodes and 6. Thus we will have: D () min( 0,,, ) The next node on its shortest path will be. 4

Bellman-Ford example The complete progress of the algorithm is shown in the table below. The notation used here is (next node on shortest path, distance to destination) Cycle 4 Initial (-,) (-,) (-,) (-,) (-,) (-,) (-,) (6,) (-,) (6,) (,0) (,8) (,) (,) (6,) (4,4) (4,) (,) (,) (6,) 4 (4,4) (4,) (,) (,) (6,) Thus the shortest path to node 6 from node is through node 4 and has distance 4. Note when the costs don't change after a cycle of the algorithm, the algorithm has terminated and found the shortest paths. Comments on Distance Vector routing: Distant vector routing was original routing protocol for ARPANET. It is the basis for the RIP (Routing Information Protocol) routing protocol used in the Internet. Variations of distance vector routing are used in some Appletalk and Cisco routers as well as in Novell s IPX, and DECnet. Two shortcomings of distance vector routing are: The convergence rate decreases as the size of network grows. The Count-to-infinity problem described next. 6

Count-to-infinity problem The Bellman-Ford algorithm can react very slowly to bad news such as a link failure. For example consider the network shown below, where each link has a cost of. Consider the shortest paths from each node to node 4 after running the Bellman-Ford Algorithm. These are listed below the nodes in the figure, using the same notation as above. 4 (,) (,) (4,) Now suppose that the link between nodes and 4 fails, in this case the distance between and 4 becomes. The progress of the algorithm after this failure is shown on the next page. The algorithm may take many iterations before it realizes the link has failed, this is called the count-to-infinity problem. 7 4 Before Failure (,) (,) (4,) After Failure (,) (,) (,) (,) (,4) (,) (,) (,4) (,) (,) (,6) (,) Several heuristic approaches have been proposed to help with this problem, one is called split horizon. With this variation, nodes do not forward their distance vector to the next node along their shortest path. For the above 8

example this speeds up the convergence, but other examples can be found where slow convergence is still an issue. 9