Routing with subnetting Example Start of header Ident = x 0 Offset = 0 � The host want to send a packet to a certain IP address Rest of header � 1). Bitwise AND between its own subnet mask & the destination IP address 1400 data bytes � 2). If the same subnet number is obtained, direct delivery over that subnet � 3). If not, it send s the packet to its default router � The job of a router changes when introduce subnetting Start of header � the entries of <Dest. NetworkNum, NextHop> -> Ident = x 1 Offset = 0 <Dest. SubnetNum, SubnetMask , NextHop> Rest of header � the router ANDs the destination address with the Subnet Mask for each 512 data bytes entry, the matched one is the entry to be use Start of header � Note: Subnets is not visible from the rest of the Internet Ident = x 1 Offset = 64 Subnet mask: 255.255.255.128 Rest of header Subnet number: 128.96.34.0 Forwarding table at router R1 128.96.34.15 512 data bytes 128.96.34.1 Subnet Number Subnet Mask Next Hop H1 Note: Offset field counts 8-byte units of data, not R1 Start of header 128.96.34.0 255.255.255.128 interface 0 Subnet mask: 255.255.255.128 individual bytes (the change has been made w/ red) 128.96.34.130 Subnet number: 128.96.34.128 Ident = x 0 Offset = 128 128.96.34.128 255.255.255.128 interface 1 128.96.34.139 128.96.34.129 Rest of header H2 128.96.33.0 255.255.255.0 R2 R2 376 data bytes H3 128.96.33.1 128.96.33.14 Spring 2004 Spring 2004 Subnet mask: 255.255.255.0 EE4272 EE4272 Subnet number: 128.96.33.0 Supernetting – Classless Interdomain Routing (CIDR) Supernetting The IP address structure (w/ class A, B, C) forces to hand out network � address space in fixed size chunks of 3 very different size � Unlike subnetting, supernetting gives appropriate # of class C address to cover the expected number of host (address utilization >50%) � Problem: if a single AS has n class C network numbers assigned, every backbone router needs n entries in its routing table for that AS Two scaling concerns in the Internet to be addressed � � address assignment efficiency (especially class B IP address) � the growth of backbone routing table Classless Interdomain Routing (CIDR) � � try to balance the desire of minimizing the routing table of the routers involved and the desire of handing out IP address efficiently by aggregating the routes (e.g. …) � Assign a portion of address space to the ISP, and let ISP assign addresses to its customer � Assign block of contiguous network numbers to nearby networks, the common parts of the network numbers -> single network prefix (used in forwarding table) � It can advise a single route to both customer by � Restrict block sizes to powers of 2 just advertising the common 19-bits prefix they � Handout blocks of class C address that share a common prefix share � Need a routing protocol can deal with these “ classless ” address with any length of the network number part (e.g. BGP) EE4272 Spring 2004 EE4272 Spring 2004 1
Interdomain Routing Supernetting � Essences: � The idea behind ASs (domain) is to provide an additional way to hierarchically aggregate routing information in a large internet, thus � “ subnetting ” allows a class B kind of IP address be improving scalability shared by multiple physical networks � Intradomain routing (w/ in a single AS): finding “optimal” paths based on the link metrics � “ supnetting ” aims to collapse the multiple class C kind of � Interdomain routing (between ASs) : concerning more on reachability of packets among ASs IP addresses that would be assigned to a single AS � Interdomain Routing : a hard problem � Exterior Gateway Protocol (EGP): limited to treelike topology(early Internet) � In general, it is possible to apply the principle (network � Border Gateway Protocol (BGP): flexible to an arbitrarily interconnected set of ASs prefixes) of CIDR in the Internet service provider network “ repeatedly ” if addresses are assigned carefully � BGP: finding any loop-free path to the intended destination � matter of scale: 140,000 prefix � impossible to calculate meaningful path costs cross multiple ASs � CIDR means prefixes may be of variable length , in case � “BGP speaker” exchange reachability infor. among ASs of some addresses may matches more than one prefix, � BGP advertises “complete path” to achieve loop-free follow the principle of “longest match” � No. of nodes involving in BGP is on the order of ASs Spring 2004 Spring 2004 EE4272 EE4272 BGP Example Speaker for AS2 advertises reachability to P and Q � Beside BGP speaker, � network 128.96, 192.4.153, 192.4.32, and 192.4.3, can be reached directly from AS2 � AS has border gateways which are responsible of Customer P 128.96 192.4.153 (AS 4) forwarding packets Regional provider A (AS 2) between ASs Customer Q 192.4.32 (AS 5) 192.4.3 Backbone network (AS 1) Customer R 192.12.69 (AS 6) Regional provider B (AS 3) Customer S 192.4.54 (AS 7) 192.4.23 Speaker for backbone advertises � networks 128.96, 192.4.153, 192.4.32, and 192.4.3 can be reached along the path (AS1, AS2) � To prevent loop, the complete AS path should be carried in the message � Speaker can cancel previously advertised paths, in case of failure � Note: A “stub AS” has a single connection to one other AS � A “transit AS” has connections to more than one other ASs EE4272 Spring 2004 EE4272 Spring 2004 2
IP Version 6 Internet Multicast � Features � 128-bit addresses (classless) � real-time service � IPv4 � authentication and security � autoconfiguration � class D addresses � end-to-end fragmentation � demonstrated with MBone � protocol extensions � multicast � uses tunneling � Header � 40-byte “base” header � Integral part of IPv6 � extension headers (fixed order, mostly fixed length) � fragmentation � problem is making it scale � source routing � authentication and security � other options Spring 2004 Spring 2004 EE4272 EE4272 Link-State Multicast Example � Each host on a LAN periodically announces the groups it belongs to by Internet Group Management Protocol (IGMP): reading assignment (P331-335) � Augment update message (link state packet-LSP) to include set of groups that have members on a particular LAN � Each router uses Dijkstra's algorithm to compute shortest-path spanning tree for each source/group pair � Each router computes and stores the cache of trees for currently active source/group pairs. � Example shortest-path multicast trees � Member of group G in color EE4272 Spring 2004 EE4272 Spring 2004 3
Distance-Vector Multicast Reverse Path Multicast (RPM) Reverse Path Broadcast (RPB) � Goal: Prune networks that have no hosts in group G � Each router already knows that shortest path to � Step 1: Determine of LAN is a leaf with no members in G destination S goes through router N � leaf if parent is the only router on the LAN � When receive multicast packet from S, forward � determine if any hosts are members of G using IGMP on all outgoing links (except the one on which � Step 2: Propagate “no members of G here” information the packet arrived), iff packet arrived from N � augment <Destination, Cost> update sent to neighbors with set of groups for which this network is � Eliminate duplicate broadcast packets by only interested in receiving multicast packets. letting “ parent ” for LAN (relative to S) forward � only happens with multicast address becomes active . � shortest path to S (learn via distance vector) � smallest address to break ties Spring 2004 Spring 2004 EE4272 EE4272 4
Recommend
More recommend