: An Introduction to Computer Networks

Slides:



Advertisements
Similar presentations
Introduction 1 Lecture 22 Network Layer (Broadcast and Multicast) slides are modified from J. Kurose & K. Ross University of Nevada – Reno Computer Science.
Advertisements

Courtesy: Nick McKeown, Stanford
CSCI 4550/8556 Computer Networks Comer, Chapter 25: Internet Routing.
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization –All routers are identical –Network is flat. Not true in Practice Hierarchical.
Routing So how does the network layer do its business?
Chapter 4 IP Multicast Professor Rick Han University of Colorado at Boulder
Slide Set 15: IP Multicast. In this set What is multicasting ? Issues related to IP Multicast Section 4.4.
CS335 Networking & Network Administration Tuesday, May 18, 2010.
MULTICASTING Network Security.
1 ECE453 – Introduction to Computer Networks Lecture 10 – Network Layer (Routing II)
ROUTING ON THE INTERNET COSC Aug-15. Routing Protocols  routers receive and forward packets  make decisions based on knowledge of topology.
Sirak Kaewjamnong Computer Network Tech and Security
1 Chapter 27 Internetwork Routing (Static and automatic routing; route propagation; BGP, RIP, OSPF; multicast routing)
Chapter 22 Network Layer: Delivery, Forwarding, and Routing
1 Computer Communication & Networks Lecture 22 Network Layer: Delivery, Forwarding, Routing (contd.)
Dynamic Routing Protocols  Function(s) of Dynamic Routing Protocols: – Dynamically share information between routers (Discover remote networks). – Automatically.
Unicast Routing Protocols  A routing protocol is a combination of rules and procedures that lets routers in the internet inform each other of changes.
Network Layer4-1 R1 R2 R3R4 source duplication R1 R2 R3R4 in-network duplication duplicate creation/transmission duplicate Broadcast Routing r Deliver.
© Janice Regan, CMPT 128, CMPT 371 Data Communications and Networking BGP, Flooding, Multicast routing.
1 Chapter 27 Internetwork Routing (Static and automatic routing; route propagation; BGP, RIP, OSPF; multicast routing)
Routing protocols Basic Routing Routing Information Protocol (RIP) Open Shortest Path First (OSPF)
Chapter 22 Network Layer: Delivery, Forwarding, and Routing Part 5 Multicasting protocol.
Chapter 15 Multicasting and Multicast Routing
1 Internet Routing. 2 Terminology Forwarding –Refers to datagram transfer –Performed by host or router –Uses routing table Routing –Refers to propagation.
© J. Liebeherr, All rights reserved 1 Multicast Routing.
TCOM 509 – Internet Protocols (TCP/IP) Lecture 06_a Routing Protocols: RIP, OSPF, BGP Instructor: Dr. Li-Chuan Chen Date: 10/06/2003 Based in part upon.
Chapter 14 1 Unicast Routing Protocols There isn’t a person anywhere that isn’t capable of doing more than he thinks he can. - Henry Ford.
An internet is a combination of networks connected by routers. When a datagram goes from a source to a destination, it will probably pass through many.
Routing protocols. 1.Introduction A routing protocol is the communication used between routers. A routing protocol allows routers to share information.
Multicast Communications
Spring 2000CS 4611 Routing Outline Algorithms Scalability.
1 Chapter 4: Internetworking (IP Routing) Dr. Rocky K. C. Chang 16 March 2004.
Chapter 25 Internet Routing. Static Routing manually configured routes that do not change Used by hosts whose routing table contains one static route.
Communication Networks Recitation 11. Multicast & QoS Routing.
ROUTING ON THE INTERNET COSC Jun-16. Routing Protocols  routers receive and forward packets  make decisions based on knowledge of topology.
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization All routers are identical Network is flat. Not true in Practice Hierarchical.
Network Layer Routing Networks: Routing.
TRANSPORT LAYER BY, Parthasarathy.g.
Chapter 4: Network Layer
Working at a Small-to-Medium Business or ISP – Chapter 6
Broadcast Routing Broadcasting: sending a packet to all N receivers
Dynamic Routing Protocols II OSPF
Multicasting protocols
Multicast Outline Multicast Introduction and Motivation DVRMP.
Routing BY, P.B.SHANMATHI.
(How the routers’ tables are filled in)
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization All routers are identical Network is flat. Not true in Practice Hierarchical.
Chapter 4: Network Layer
Introduction to Communication Networks
Delivery, Forwarding, and Routing
Intra-Domain Routing Jacob Strauss September 14, 2006.
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization All routers are identical Network is flat. Not true in Practice Hierarchical.
شبکه هاي کامپيوتري فصل پنجم: لايه شبکه (NetworkLayer)
Routing.
Chapter 5: Dynamic Routing
Dynamic Routing Protocols II OSPF
CS 4700 / CS 5700 Network Fundamentals
CS 3700 Networks and Distributed Systems
Multicast Outline Multicast revisited
Chapter 4: Network Layer
CS 3700 Networks and Distributed Systems
Chapter 4: Network Layer
Network Layer Routing Networks: Routing.
Chapter 4: Network Layer
Working at a Small-to-Medium Business or ISP – Chapter 6
Computer Networks Protocols
Routing.
Implementing Multicast
Optional Read Slides: Network Multicast
Dynamic routing Routing Algorithm (Dijkstra / Bellman-Ford) – idealization All routers are identical Network is flat. Not true in Practice Hierarchical.
Presentation transcript:

371-1-0291: An Introduction to Computer Networks Homepage http://help.cse.bgu.ac.il/cse/Courses/list.asp Handout #4: Internetworking and Routing Additional Reading Text book: Chap. 4.2-4.4

Outline Techniques Routing in the Internet Multicast Routing Reliable Flooding Distributed Bellman Ford Algorithm Dijkstra’s Shortest Path First Algorithm Routing in the Internet Hierarchy and Autonomous Systems Interior Routing Protocols: RIP, OSPF Exterior Routing Protocol: BGP Multicast Routing

Where in the OSI Layer? Protocol Stack App Transport Network IP + Routing Data Hdr IP Datagram Link

The Problem “A” “B” R2 R1 R4 R3 How does R1 choose a route to host B?

An algorithm ensuring all nodes get a copy of an update packet Reliable Flooding An algorithm ensuring all nodes get a copy of an update packet R1 Un update packet: Node sequence update id number data Algorithm: A source node sends out the packet on all ports Each node receiving the packet checks the sequence no. and if more recent, stores it and sends it out on all ports but the ingress port Each node receiving the packet acks the directly node which sent it A sending node, not receiving an ack within a T/O, retransmits

Reliable Flooding Advantages: Reliable transmission. Works also when network topology is unknown. If the network is connected, every node gets a copy of the packet Disadvantages: Some nodes receive multiple copies of the packet Packets can go round in loops forever. Waste of network resources To prevent looping for ever, a TTL is added to packet Useful only for important updates – not for regular routing Node sequence TTL update id number data

Bellman-Ford Algorithm Objective: Finds the minimum cost path from every node to every other node Example: Determine the route from (R1, …, R7) to R8 that minimizes the cost. Examples of link cost: Distance, data rate, price, congestion/delay, … R1 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8

B-F is a Distance Vector Algorithm 1 1 4 R1 R2 R4 R6 3 2 2 2 R7 R5 2 3 4 R3 R8 The solution is a spanning tree with R8 as the root of the tree (link costs are cost in the direction to R8). The Bellman-Ford Algorithm finds all spanning trees.

The Distributed Bellman-Ford Algorithm

Bellman-Ford Algorithm - Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 R1 Inf R2 R3 4, R8 R4 R5 2, R8 R6 R7 3, R8 R2 R5 R7 R4 R6 R8 R3 R1 1 4 2 3

Bellman-Ford Algorithm - Example 6 4 6 2 1 1 4 R1 R2 R4 R6 3 2 3 2 2 2 R7 3 4 R5 2 4 R3 R8 R8 R6 R4 R2 R1 R3 R5 1 4 2 3 5 4 5 2 R7 Solution R1 5, R2 R2 4, R5 R3 4, R8 R4 R5 2, R8 R6 R7 3, R8

Bellman-Ford Algorithm Questions: How long can the algorithm take to run? How do we know that the algorithm always converges? What happens when link costs change, or when routers/links fail?

A Problem with Bellman-Ford “Bad news travels slowly” 1 1 1 R1 R2 R3 R4 Consider the update of distances to R4, given the optimal ones when all links are active Time R1 R2 R3 3,R2 2,R3 1, R4 R3 R4 fails 1 3,R2 2,R3 3,R2 2 3,R2 4,R3 3,R2 3 5,R2 4,R3 5,R2 … “Counting to infinity” … … …

Counting to Infinity Problem Solutions Set infinity = “some small integer” (e.g. 16). Stop when count = 16. Split Horizon: “Because R2 received lowest cost path from R3, it does not advertise cost to R3 “ Split-horizon with poison reverse: “R2 advertises infinity to R3 “

Dijkstra’s Shortest Path First (SPF) Alg Objective: Finds the minimum cost path from every node to every other node Executed by every node based on the following complete network topology and link costs When completed at node, say R8, C(n) will contain the minimum cost path from R8 to node n

Dijkstra’s Shortest Path First (SPF) Alg Each router calculates lowest cost path to all its neighbors, starting from itself; At each step of the algorithm, a router adds a node to M to which it can reach with its current minimum cost For every node outside M, updates the minimum path cost to it

Getting Network Topology for SPF Done by the Reliable Flooding algorithm that sends the following Link State Packet (LSP): LSP are sent out whenever the state of an attached link changes (up/down), or when an Interval Timer expires Node sequence TTL attached links id number and their costs

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 is the minimum

Dijkstra’s Shortest Path First Algorithm Example is the minimum R1 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8

Dijkstra’s Shortest Path First Algorithm Example is the minimum R1 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 is the minimum

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 is the minimum

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 is the minimum

Dijkstra’s Shortest Path First Algorithm Example 1 1 4 R2 R4 R6 2 3 2 2 R7 3 R5 2 R3 4 R8 is the minimum

Outline Techniques Routing in the Internet Multicast Routing Reliable Flooding Distributed Bellman Ford Algorithm Dijkstra’s Shortest Path First Algorithm Routing in the Internet Hierarchy and Autonomous Systems Interior Routing Protocols: RIP, OSPF Exterior Routing Protocol: BGP Multicast Routing

Routing in the Internet The Internet uses hierarchical routing The Internet is split into Autonomous Systems (AS’s) Examples of AS’s: Stanford (32), HP (71), MCI Worldcom (17373) Try: whois –h whois.arin.net ASN “MCI Worldcom” Within an AS, the administrator chooses an Interior Gateway Protocol (IGP) Examples of IGPs: RIP (rfc 1058), OSPF (rfc 1247). Between AS’s, the Internet uses an Exterior Gateway Protocol AS’s today use the Border Gateway Protocol, BGP-4 (rfc 1771)

Routing in the Internet AS ‘A’ AS ‘B’ AS ‘C’ BGP BGP Interior Gateway Protocol Interior Gateway Protocol Interior Gateway Protocol Stub AS – single AS neighbor Transit AS e.g. backbone service provider Stub AS

Routing within a Stub AS In stubs, there is only one exit point, so routers within the AS can use default routing. Each router knows all Network IDs within AS. Packets destined to another AS are sent to the default router. Default router is the border gateway to the next AS. Routing tables in Stub AS’s tend to be small. Multihomed AS – An AS connected to several AS but rejects transient traffic

Interior Routing Protocols RIP (Routing Information Protocol) Uses distributed Bellman-Ford algorithm. Updates (in a RIP packet) are sent every 30 seconds. No authentication in RIP ver. 1; password in ver. 2 Originally in BSD UNIX. OSPF (Open SPF) Link-state updates (LSU) sent (using reliable flooding) as and when required. Every router runs Dijkstra’s algorithm. Authenticated updates. Autonomous system may be partitioned into “areas”. Allows multiple paths with the same cost to a destination

Interior Routing Protocols Authentication of LSU packets To prevent, e.g., forged advertisement of zero cost Early OSPF uses 8-byte password Strong cryptography in newer versions “Areas” as a further hierarchy layer An AS can be partitioned into “areas” Adds scalability to the OSPF alg A router knows only how to reach the “areas” – not to all networks

Exterior Routing Protocols Problems: Topology: The Internet is a complex mesh of different AS’s with very little structure. Autonomy of AS’s: Each AS defines link costs in different ways, so not possible to find lowest cost paths. Trust: Some AS’s can’t trust others to advertise good routes (e.g. two competing backbone providers), or to protect the privacy of their traffic (e.g. two warring nations). Policies: Different AS’s have different objectives (e.g. route over fewest hops; use one provider rather than another).

Border Gateway Protocol (BGP-4) Replaces the earlier EGP (Exterior Gateway Protocol) BGP is not a link-state nor distance-vector routing protocol. BGP advertises complete paths (a list of AS’s). Example of path advertisement: “The network 171.64/16 can be reached via the path {AS1, AS5, S13}”. Paths with loops are detected locally and ignored. Local policies pick the preferred path among options. When a link/router fails, the path is “withdrawn” AS numbers (ASN) in messages are unique On critical link/node failure, BGP routers advertise “withdrawn routes” Uses TCP protocol to exchange messages and copes with CIDR

Multicast Routing Outline Applications that need multicast. Trees, addressing and forwarding. Multicast routing Distance Vector (DVMRP) Protocol Independent Multicast (PIM) Some interesting questions…

Applications that need multicast One way, single sender: “one-to-many” TV Non-interactive learning Database update Information dispersal (e.g., CEO addressing an org) Two way, interactive, multiple sender: “many-to-many” Teleconference Interactive learning

Multicast Routing Outline Applications that need multicast. Trees, addressing and forwarding. Multicast routing Distance Vector (DVMRP) Protocol Independent Multicast (PIM) Some interesting questions…

Multicast Trees - Example

Multicast Routing A multicast tree is a spanning tree with the sender at the root, spanning all the members of the group.

Multicast Trees e.g., a teleconference Sender/Speaker Multicast Group (S1,G) S1 Class D S1 R

Multicast Trees and Addressing All members of the group share the same “Class D” Group Address. An end station may be a member of multiple groups. An end-station “joins” a multicast group by (periodically) telling its nearest router that it wishes to join (uses IGMP – Internet Group Management Protocol). Routers maintain “soft-state” indicating which end-stations have subscribed to which groups.

Multicast Trees e.g., a teleconference Class D S2 R S2 Sender/Speaker Multicast Group (S2,G)

Multicast Forwarding is Source-specific Group Address Src Address Src Interface Dst Interface G S1 1 2,3 S2 2 1,3 R forwards packet to all interfaces 2 S1 G 1 3 1 S2 G 2 forwards packet to all interfaces 3

Multicast Routing Outline Applications that need multicast. Trees, addressing and forwarding. Multicast routing Distance Vector (DVMRP) Protocol Independent Multicast (PIM) Some interesting questions…

Distance-vector Multicast RPB: Reverse-Path Broadcast Uses existing unicast shortest path routing table. If packet arrived through interface that is the shortest path to the packet’s SA, then forward packet to all interfaces. Else drop packet.

Distance-vector Multicast RPB: Reverse-Path Broadcast Sender/Speaker Multicast Group (S1,G) Address Port Unicast DV Routing Table S1 S1 1 1 3 LAN 2 Shortest Path to Source Q: Is it shortest path from source?

Distance-vector Multicast RPB: Reverse-Path Broadcast Sender/Speaker Multicast Group (S1,G) S1 Designated Parent Router: One parent router picked per LAN (one “closest” to source). LAN

Distance-vector Multicast RPM: Reverse-Path Multicast RPM = RPB + Prune (“not interested”) RPB used when a source starts to send to a new group address. Routers that are not interested in a group, send prune messages up the tree towards source. Prunes sent implicitly by not indicating interest in a group. DVMRP works this way.

Protocol Independent Multicast (PIM) PIM-DM (Dense Mode) uses RPM. PIM-SM (Sparse Mode) designed to be more efficient than DVMRP. Routers explicitly join multicast tree by sending unicast Join and Prune messages. Routers join a multicast tree via a RP (Rendezvous Point) for each group. Several RPs per domain (picked in a complex way). Provides either: Shared tree for all senders (default). Source-specific tree.

PIM-SM Example Unicast to R3: (S,G) Unicast to RP: (*, G) RP Source knows to send all G packets to RP. Source “tunnels” mcast-in-ucast packets to RP. RP unwraps mcast pkt and forwards to local tree. Unicast to RP: (*, G) RP knows R1 has joined R2 learns to send (*,G) packets to R1 RP R2 S IGMP Join R1 Sender/Source

PIM-SM Example Optional Source-specific join to bypass RP router: Routers along the way learn new path for (S,G). RP R2 S R1 Sender/Source

Multicast Routing Outline Applications that need multicast. Trees, addressing and forwarding. Multicast routing Distance Vector (DVMRP) Protocol Independent Multicast (PIM) Some interesting questions…

Multicast: Interesting Questions How to make multicast reliable? How to implement flow-control? How to support/provide different rates for different end users? How to secure a multicast conversation? Will multicast become widespread?