network layer
play

Network Layer Goals: Overview: last time understand principles - PDF document

Network Layer Goals: Overview: last time understand principles network layer services behind network layer o IP addressing services: o routing principle: path o o routing (path selection selection) today o dealing with scale IP


  1. Network Layer Goals: Overview: ¸ last time ¸ understand principles network layer services behind network layer o IP addressing services: o routing principle: path o o routing (path selection selection) ¸ today o dealing with scale IP o o how a router works hierarchical routing o o advanced topics: IPv6, Internet routing protocols o multicast reliable transfer ¸ instantiation and ß intra-domain ß inter-domain implementation in what’s inside a router? the Internet o IPv6 o multicast routing o Mobility o 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 1 Routing Algorithm classification Global or decentralized Static or dynamic? information? Static: Global: ¸ routes change slowly over ¸ all routers have complete time topology, link cost info Dynamic: ¸ “link state” algorithms ¸ routes change more quickly Decentralized: o periodic update ¸ router knows physically- connected neighbors, link o in response to link cost costs to neighbors changes ¸ iterative process of computation, exchange of info with neighbors ¸ “distance vector” algorithms 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 2 Distance Vector - Link State ¸ Link State o Alla pratar med alla o Berättar bara om sina egna länkar ¸ Distance Vector o Varje nod pratar endast med närmsta granne o Berättar allt den vet 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 3 1

  2. Distance Vector Routing: overview Iterative, asynchronous: Each node: each local iteration caused by: ¸ local link cost change wait for (change in local link ¸ message from neighbor: its least cost path change cost of msg from neighbor) from neighbor Distributed: ¸ each node notifies recompute distance table neighbors only when its least cost path to any destination changes if least cost path to any dest neighbors then notify o their neighbors if has changed, notify necessary neighbors 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 4 Distance Vector Algorithm: At all nodes, X: 1 Initialization: 2 for all adjacent nodes v: X 3 D (*,v) = infty /* the * operator means "for all rows" */ X 4 D (v,v) = c(X,v) 5 for all destinations, y X 6 send min D (y,w) to each neighbor /* w over all X's neighbors */ w 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 5 Distance Vector Algorithm (cont.): 8 loop 9 wait (until I see a link cost change to neighbor V 10 or until I receive update from neighbor V) 11 12 if (c(X,V) changes by d) 13 /* change cost to all dest's via neighbor v by d */ 14 /* note: d could be positive or negative */ X X 15 for all destinations y: D (y,V) = D (y,V) + d 16 17 else if (update received from V wrt destination Y) 18 /* shortest path from V to some Y has changed */ 19 /* V has sent a new value for its min D V (Y,w) */ w 20 /* call this received new value "newval" */ X 21 for the single destination y: D (Y,V) = c(X,V) + newval 22 X 23 if we have a new min D (Y,w)for any destination Y w X 24 send new value of min D (Y,w) to all neighbors w 25 26 forever 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 6 2

  3. Distance Vector: link cost changes Link cost changes: 1 ¸ node detects local link cost change Y ¸ updates distance table (line 15) 4 1 X ¸ if cost change in least cost path, Z 50 notify neighbors (lines 23,24) algorithm “good terminates news travels fast” 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 7 Distance Vector: link cost changes Link cost changes: good news travels fast ¸ 60 bad news travels slow - “count to ¸ Y infinity” problem! 4 1 Line 21 ( D (Y,V) = c(X,V) + newval ) X Z ¸ 50 algorithm continues on! 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 8 Distance Vector: poisoned reverse If Z routes through Y to get to X : 60 ¸ Z tells Y its (Z’s) distance to X is Y 4 1 infinite (so Y won’t route to X via Z) X Z 50 algorithm terminates 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 9 3

  4. Comparison of LS and DV algorithms Message complexity Robustness: what happens if router malfunctions? ¸ LS: with n nodes, E links, LS: O(nE) msgs sent each node can advertise incorrect ¸ DV: exchange between o link cost neighbors only each node computes only its o o convergence time varies own table DV: Speed of Convergence DV node can advertise o ¸ LS: O(n**2) algorithm incorrect path cost requires O(nE) msgs each node’s table used by o o may have oscillations others ¸ DV: convergence time varies ß error propagate thru network o may be routing loops o count-to-infinity problem 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 10 Hierarchical Routing Our routing study thus far - idealization ¸ all routers identical ¸ network “flat” … not true in practice administrative scale: with 200 million destinations: autonomy ¸ can’t store all dest’s in ¸ internet = network of routing tables! networks ¸ routing table exchange ¸ each network admin may would swamp links! want to control routing in its own network 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 11 Hierarchical Routing ¸ aggregate routers into gateway routers regions, “autonomous ¸ special routers in AS systems” (AS) ¸ run intra-AS routing ¸ routers in same AS protocol with all other routers in AS run same routing ¸ also responsible for protocol routing to destinations o “intra-AS” routing outside AS protocol o run inter-AS routing o routers in different AS protocol with other can run different intra- gateway routers AS routing protocol 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 12 4

  5. Intra-AS and Inter-AS routing C.b Gateways: B.a •perform inter-AS A.a routing amongst b c A.c a a themselves C b a B •perform intra-AS d c routers with other b A routers in their AS network layer inter-AS, intra-AS link layer routing in physical layer gateway A.c 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 13 Intra-AS and Inter-AS routing Inter-AS routing C.b B.a between A.a Host A and B b c A.c h2 a a C b a B Host d Intra-AS routing c h1 b A within AS B Intra-AS routing within AS A 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 14 Routing in the Internet ¸ The Global Internet consists of Autonomous Systems (AS) interconnected with each other: o Stub AS : small corporation o Multihomed AS : large corporation (no transit) o Transit AS : provider ¸ Two-level routing: o Intra-AS: administrator is responsible for choice o Inter-AS: unique standard 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 15 5

  6. Intra-AS Routing ¸ Also known as Interior Gateway Protocols (IGP) ¸ Most common IGPs: o RIP: Routing Information Protocol o OSPF: Open Shortest Path First o IGRP: Interior Gateway Routing Protocol (Cisco propr.) 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 16 RIP ( Routing Information Protocol) ¸ Distance vector algorithm ¸ Included in BSD-UNIX Distribution in 1982 ¸ Distance metric: # of hops (max = 15 hops) o Can you guess why? ¸ Distance vectors: exchanged every 30 sec via Response Message (also called advertisement ) ¸ Each advertisement: route to up to 25 destination nets ¸ RIP v1 RFC 1058 ¸ RIP v2 RFC 1723 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 17 RIP: Link Failure and Recovery If no advertisement heard after 180 sec --> neighbor/link declared dead o routes via neighbor invalidated o new advertisements sent to neighbors o neighbors in turn send out new advertisements (if tables changed) o link failure info quickly propagates to entire net o poison reverse used to prevent ping-pong loops (infinite distance = 16 hops) 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 18 6

  7. RIP Table processing ¸ RIP routing tables managed by a pplication-level process called route-d (daemon) ¸ advertisements sent in UDP packets, periodically repeated (port 520) 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 19 RIP Table example (continued) Router: giroflee.eurocom.fr Destination Gateway Flags Ref Use Interface -------------------- -------------------- ----- ----- ------ --------- 127.0.0.1 127.0.0.1 UH 0 26492 lo0 192.168.2. 192.168.2.5 U 2 13 fa0 193.55.114. 193.55.114.6 U 3 58503 le0 192.168.3. 192.168.3.5 U 2 25 qaa0 224.0.0.0 193.55.114.6 U 3 0 le0 default 193.55.114.129 UG 0 143454 ¸ Three attached class C networks (LANs) ¸ Router only knows routes to attached LANs ¸ Default router used to “go up” ¸ Route multicast address: 224.0.0.0 ¸ Loopback interface (for debugging) 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 20 OSPF (Open Shortest Path First) ¸ “open”: publicly available, v2 RFC 2178 ¸ Uses Link State algorithm o LS packet dissemination o Topology map at each node o Route computation using Dijkstra’s algorithm ¸ OSPF advertisement carries one entry per neighbor router ¸ Advertisements disseminated to entire AS (via flooding) 3/10 Datakommunikation & Internet, Anders Broberg, UmU Network 2 21 7

Recommend


More recommend