Ch. 2 – Introduction to Classless Routing CCNA 3 – Spring 2008 Overview IP Addressing • Legacy Classful IP Addressing – Depletion of IPv4 Address Space – Subnetting • Evolution – Classless Addressing – IPv6 • IPv4 Enhancements – Classless interdomain routing (CIDR) – Route summarization – Network Address Translation (NAT/PAT) – Variable length subnet masking (VLSM) Routing Protocols • Classful Routing Protocol (RIPv1) • Classless Routing Protocol (RIPv2) Rick Graziani graziani@cabrillo.edu 2 IP Addressing •IP Addressing •Legacy Classful IP Addressing –Depletion of IPv4 Address Space –Subnetting •Evolution –Classless Addressing –IPv6 •IPv4 Enhancements –Classless interdomain routing (CIDR) –Route summarization –Network Address Translation (NAT/PAT) –Variable length subnet masking (VLSM) Legacy IPv4 Classful Addresses Rick Graziani graziani@cabrillo.edu 4 Classful IP Addressing • In the early days of the Internet, IP addresses were allocated to • • • • • • organizations based on request rather than actual need. When an organization received an IP network address, that address was associated with a “Class”, A, B, or C. This class also determined the default or Major Mask for the network. This is known as Classful IP Addressing The first octet of the address determined what class the network belonged to and which bits were the network bits and which bits were the host bits. Until 1985, there were no subnet masks. Formalized in 1985 (RFC 950), the subnet masks were introduced to break a single class A, B or C network in to smaller pieces. Rick Graziani graziani@cabrillo.edu 5 Classful: The class determines the Major Network Mask Classful IP Addressing • The Class determined the Major or Base Network Mask, also known as the Default Mask. • Classful IP Addressing the class determines the Major Network Mask. 194.168.1.3 Class C Default Mask: 255.255.255.0 Network: 194.168.1.0 1.12.100.31 Class A Default Mask: 255.0.0.0 Network: 1.0.0.0 150.30.77.5 Class B Default Mask: 255.255.0.0 Network: 150.30.0.0 Rick Graziani graziani@cabrillo.edu 6 IP addressing crisis and Classless Addressing • • • • • IPv4 Addressing Crisis – Address Depletion – Internet Routing Table explosion 1985 (RFC 950), the subnet masks – Allowed organization to create their own separate networks without requesting new ones 1992 when the IETF introduced CIDR (Classless Interdomain Routing), making the address class meaning less. – This is known as Classless IP Addressing. Classless IP Addressing the ISP provides both the network address and the major network mask to the customer. Today’s networks are classless, except for some things like the structure of Cisco’s IP routing table and Classful routing protocols like RIPv1 and IGRP. Rick Graziani graziani@cabrillo.edu 7 Classless: The ISP determines the mask Classless IP Addressing • The value of the first octet is meaningless. • Classless IP Addressing the ISP provides the Major or Base (Default) network mask. 194.168.1.3 Class C Major Network Mask: 255.0.0.0 Network: 194.0.0.0 1.12.100.31 Class A Major Network Mask: 255.255.0.0 Network: 1.12.0.0 150.30.77.5 Class B Major Network Mask: 255.255.255.0 Network: 172.30.77.0 Rick Graziani graziani@cabrillo.edu 8 Subnetting Classful IP Addressing 194.168.1.3 Class C Default Mask: 255.255.255.0 Network: 194.168.1.0 Classless IP Addressing 194.168.1.3 Class C Major Network Mask: 255.0.0.0 Network: 194.0.0.0 – Classless: Both the IP Address and Network Mask are provided – Classful: The IP Address is provided and the Network Mask is derived from the value of the first octet of the IP Address Rick Graziani graziani@cabrillo.edu 9 All Zeros and All Ones Subnets • Number of usable subnets – In the past, because of legacy equipment and software, some devices could not use the all 0’s (first) and/or all 1’s (last subnets) – In today’s networks, the all 0’s (first) and/or all 1’s (last subnets) are usable subnets! – To properly determine the number of usable subnets (for example on an exam), it should be stated for clarity if any of the subnets are not usable. – It should never be assumed that the all 0’s (first) and/or all 1’s (last subnets) are not usable subnets. Rick Graziani graziani@cabrillo.edu 10 All Zeros and All Ones Subnets Using the All Ones and All Zeroes Subnet • There is no command to enable or disable the use of the all-ones subnet, it is enabled by default. Router(config)#ip subnet-zero • The use of the all-ones subnet has always been explicitly allowed and the use of subnet zero is explicitly allowed since Cisco IOS version 12.0. RFC 1878 states, "This practice (of excluding all-zeros and all-ones subnets) is obsolete! Modern software will be able to utilize all definable networks." Today, the use of subnet zero and the all-ones subnet is generally accepted and most vendors support their use, though, on certain networks, particularly the ones using legacy software, the use of subnet zero and the all-ones subnet can lead to problems.” CCO: Subnet Zero and the All-Ones Subnet http://www.cisco.com/en/US/tech/tk648/tk361/technologies_tech_note091 86a0080093f18.shtml Rick Graziani graziani@cabrillo.edu 11 Need a Subnet Review? • If you need a review of subnets, please review the following links: • • • • • Classless Subnetting Explained (PDF) Worksheet: Classless Subnetting Worksheet (Excel spreadsheet) Nutshell: Classless Subnetting in a Nutshell (Excel spreadsheet) Nutshell: Classful Subnetting in a Nutshell Article: Regional Internet Registry - How IP Addresses are Allocated Rick Graziani graziani@cabrillo.edu 12 Long Term Solution: IPv6 (coming) • • • • • • IPv6, or IPng (IP – the Next Generation) uses a 128-bit address space, yielding 340,282,366,920,938,463,463,374,607,431,768,211,456 possible addresses. IPv6 has been slow to arrive IPv4 revitalized by new features, making IPv6 a luxury, and not a desperately needed fix IPv6 requires new software; IT staffs must be retrained IPv6 will most likely coexist with IPv4 for years to come. For more information on IPv6, see: –IPv6 Overview Rick Graziani graziani@cabrillo.edu 13 IPv4 Enhancements • Private Addressing - RFC 1918 • NAT/PAT (Network Address Translation / Port Address • • Translation) – RFC CIDR (Classless Inter-Domain Routing) – RFCs 1517, 1518, 1519, 1520 VLSM (Variable Length Subnet Mask) – RFC 1009 Rick Graziani graziani@cabrillo.edu 14 Private IP addresses (RFC 1918) • If addressing any of the following, these private addresses can be used instead of globally unique addresses: – A non-public intranet (internal network) – A test lab – A home network • This allows network administrators to assign many more IP Addresses than what they may have been allocated by their provider. Rick Graziani graziani@cabrillo.edu 15 IPv4 Enhancements • Private Addressing - RFC 1918 • NAT/PAT (Network Address Translation / Port Address • • Translation) – RFC CIDR (Classless Inter-Domain Routing) – RFCs 1517, 1518, 1519, 1520 VLSM (Variable Length Subnet Mask) – RFC 1009 Rick Graziani graziani@cabrillo.edu 16 NAT Example • Network Address Translation (NAT) allows Private IP Addresses to • • • be converted to public IP Addresses (one-to-one translation). Port Address Translation (PAT) allows multiple private IP addresses to be translated by a single public address (many-to-one translation). This solves the limitation of NAT which is one-to-one translation. We will examine NAT and PAT in more detail later this semester. Rick Graziani graziani@cabrillo.edu 17 IPv4 Enhancements • Private Addressing - RFC 1918 • NAT/PAT (Network Address Translation / Port Address • • Translation) – RFC CIDR (Classless Inter-Domain Routing) – RFCs 1517, 1518, 1519, 1520 VLSM (Variable Length Subnet Mask) – RFC 1009 Rick Graziani graziani@cabrillo.edu 18 CIDR (Classless Inter-Domain Routing) • By 1992, members of the IETF were having serious concerns about the • • • • • exponential growth of the Internet and the scalability of Internet routing tables. The IETF was also concerned with the eventual exhaustion of 32-bit IPv4 address space. Projections were that this problem would reach its critical state by 1994 or 1995. IETF’s response was the concept of Supernetting or CIDR, “cider”. To CIDR-compliant routers, address class is meaningless. – The network portion of the address is determined by the network subnet mask or prefix-length (/8, /19, etc.) – The first octet (first two bits) of the network address (or networkprefix) is NOT used to determine the network and host portion of the network address. CIDR helped reduced the Internet routing table explosion with supernetting and reallocation of IPv4 address space. Rick Graziani graziani@cabrillo.edu 19 Active BGP entries Date of Graph: 22 Aug 2006 For information on BGP visit: http://www.potaroo.net/ispcol/2006-05/bgp.html Rick Graziani graziani@cabrillo.edu 20 CIDR (Classless Inter-Domain Routing) • First deployed in 1994, CIDR dramatically improves IPv4’s scalability • and efficiency by providing the following: – Eliminates traditional Class A, B, C addresses allowing for more efficient allocation of IPv4 address space. – Supporting route aggregation (summarization), also known as supernetting, where thousands of routes could be represented by a single route in the routing table. • Route aggregation also helps prevent route flapping on Internet routers using BGP. Flapping routes can be a serious concern with Internet core routers. CIDR allows routers to aggregate, or summarize, routing information and thus shrink the size of their routing tables. – Just one address and mask combination can represent the routes to multiple networks. – Used by IGP routers within an AS and EGP routers between AS. Rick Graziani graziani@cabrillo.edu 21 Without CIDR, a router must maintain individual routing table entries for these class B networks. With CIDR, a router can summarize these routes using a single network address by using a 13-bit prefix: 172.24.0.0 /13 Steps: 1. Count the number of left-most matching bits, /13 (255.248.0.0) 2. Add all zeros after the last matching bit: 172.24.0.0 = 10101100 00011000 00000000 00000000 Rick Graziani graziani@cabrillo.edu 22 CIDR (FYI) • By using a prefix address to summarizes routes, administrators can • • • • keep routing table entries manageable, which means the following – More efficient routing – A reduced number of CPU cycles when recalculating a routing table, or when sorting through the routing table entries to find a match – Reduced router memory requirements Route summarization is also known as: – Route aggregation – Supernetting Supernetting is essentially the inverse of subnetting. CIDR moves the responsibility of allocation addresses away from a centralized authority (InterNIC). Instead, ISPs can be assigned blocks of address space, which they can then parcel out to customers. Rick Graziani graziani@cabrillo.edu 23 ISP/NAP Hierarchy - “The Internet: Still hierarchical after all these years.” Jeff Doyle (Tries to be anyways!) NAP (Network Access Point) Network Service Provider Regional Service Provider ISP Subscribers ISP Subscribers Rick Graziani graziani@cabrillo.edu ISP Subscribers Network Service Provider Regional Service Provider Regional Service Provider ISP ISP Subscribers Subscribers Regional Service Provider ISP Subscribers ISP Subscribers ISP Subscribers 24 Supernetting Example • Company XYZ needs to address 400 hosts. • Its ISP gives them two contiguous Class C addresses: • • – 207.21.54.0/24 – 207.21.55.0/24 Company XYZ can use a prefix of 207.21.54.0 /23 to supernet these two contiguous networks. (Yielding 510 hosts) 207.21.54.0 /23 – 207.21.54.0/24 – 207.21.55.0/24 Rick Graziani graziani@cabrillo.edu 23 bits in common 25 Supernetting Example • With the ISP acting as the addressing authority for a CIDR block of addresses, the ISP’s customer networks, which include XYZ, can be advertised among Internet routers as a single supernet. Rick Graziani graziani@cabrillo.edu 26 CIDR and the Provider Another example of route aggregation. Rick Graziani graziani@cabrillo.edu 27 Summarization from the customer networks to their provider. ? ? 1. Count the number of left-most matching bits 2. Add all zeros after the last matching bit 200.199.48.32/27 11001000 11000111 00110000 00100000 200.199.48.64/27 11001000 11000111 00110000 01000000 200.199.48.96/27 11001000 11000111 00110000 01100000 ? ? 200.199.56.0/24 200.199.57.0/24 ? Rick Graziani graziani@cabrillo.edu 11001000 11000111 0011100 0 00000000 11001000 11000111 0011100 1 00000000 ? 28 Summarization from the customer networks to their provider. 200.199.48.0/25 200.199.56.0/23 1. Count the number of left-most matching bits 2. Add all zeros after the last matching bit 200.199.48.32/27 200.199.48.64/27 200.199.48.96/27 200.199.48.0/25 11001000 11000111 00110000 0 0100000 11001000 11000111 00110000 0 1000000 11001000 11000111 00110000 0 1100000 11001000 11000111 00110000 0 0000000 200.199.56.0/24 200.199.57.0/24 200.199.56.0/23 11001000 11000111 0011100 0 00000000 11001000 11000111 0011100 1 00000000 11001000 11000111 0011100 0 00000000 Rick Graziani graziani@cabrillo.edu 29 CIDR and the provider 200.199.48.0/25 200.199.56.0/23 Further summarization happens with the next upstream provider. 200.199.48.0/25 200.199.49.0/25 200.199.56.0/23 11001000 11000111 0011 0000 00000000 11001000 11000111 0011 0001 00000000 11001000 11000111 0011 1000 00000000 200.199.48.0/20 11001000 11000111 0011 0000 00000000 20 bits in common Rick Graziani graziani@cabrillo.edu 30 CIDR Restrictions • CIDR requires classless routing protocols for dynamic routing. • Dynamic routing protocols must send network address and mask • (prefix-length) information in their routing updates. However, you can still configure summarized static routes, after all, that is what a 0.0.0.0/0 route is. Rick Graziani graziani@cabrillo.edu 31 Summarized and Specific Routes: Longest-bit Match (More Specific Match or Longest Match Wins) Merida Summarized Update Specific Route Update 172.16.0.0/16 172.16.1.0/24 172.16.5.0/24 172.16.5.0/24 Quito Cartago 172.16.2.0/24 172.16.10.0/24 • Merida receives a summarized /16 update from Quito and a more • • • specific /24 update from Cartago. Merida will include both routes in the routing table. Merida will forward all packets matching at least the first 24 bits of 172.16.5.0 to Cartago (172/16/5/0/24), longest-bit match. Merida will forward all other packets matching at least the first 16 bits to Quito (172.16.0.0/16). Rick Graziani graziani@cabrillo.edu 32 Route flapping • • • • • • Route flapping occurs when a router interface alternates rapidly between the up and down states. Route flapping can cripple a router with excessive updates and recalculations. However, the summarization configuration prevents the RTC route flapping from affecting any other routers. The loss of one network does not invalidate the route to the supernet. While RTC may be kept busy dealing with its own route flap, RTZ, and all upstream routers, are unaware of any downstream problem. Summarization effectively insulates the other routers from the problem of route flapping. Rick Graziani graziani@cabrillo.edu 33 IPv4 Enhancements • Private Addressing - RFC 1918 • NAT/PAT (Network Address Translation / Port Address • • Translation) – RFC CIDR (Classless Inter-Domain Routing) – RFCs 1517, 1518, 1519, 1520 VLSM (Variable Length Subnet Mask) – RFC 1009 Rick Graziani graziani@cabrillo.edu 34 VLSM (Variable Length Subnet Mask) • Limitation of using only a single • • subnet mask across a given networkprefix (network address, the number of bits in the mask) was that an organization is locked into a fixednumber of fixed-sized subnets. 1987, RFC 1009 specified how a subnetted network could use more than one subnet mask. VLSM = Subnetting a Subnet – “If you know how to subnet, you can do VLSM!” Rick Graziani graziani@cabrillo.edu Subnets 10.0.0.0/16 10.1.0.0/16 10.2.0.0/16 10.2.0.0/24 10.2.1.0/24 10.2.2.0/24 Etc. 10.2.255.0/24 10.3.0.0/16 Etc. 10.255.0.0/16 35 VLSM – Simple Example 1st octet 2nd octet 3rd octet 4th octet 10.0.0.0/8 10 Host Host Host 10.0.0.0/16 10 Subnet Host Host 10.0.0.0/16 10 0 Host Host 10.1.0.0/16 10.2.0.0/16 10.n.0.0/16 10.255.0.0/16 10 10 10 10 1 2 … 255 Host Host Host Host Host Host Host Host • Subnetting a /8 subnet using a /16 mask gives us 256 subnets with • 65,536 hosts per subnet. Let’s take the 10.2.0.0/16 subnet and subnet it further… Rick Graziani graziani@cabrillo.edu 36 VLSM – Simple Example Network Subnet Host Host 10.2.0.0/16 10 2 Host Host 10.2.0.0/24 10 2 Subnet Host 10.2.0.0/24 10.2.1.0/24 10 10 2 2 0 1 Host Host 10.2.n.0/24 10.2.255.0/24 10 10 2 2 … 255 Host Host • Note: 10.2.0.0/16 is now a summary of all of the 10.2.0.0/24 subnets. Rick Graziani graziani@cabrillo.edu 37 VLSM – Simple Example 10.0.0.0/8 Subnet 10.0.0.0/16 10.1.0.0/16 “subnetted using /16” 1st host Last host Broadcast 10.0.0.1 10.0.255.254 10.0.255.255 10.1.0.1 10.1.255.254 10.1.255.255 10.2.0.0/16 “sub-subnetted using /24” –Subnet 1st host Last host Broadcast –10.2.0.0/24 10.2.0.1 10.2.0.254 10.2.0.255 –10.2.1.0/24 10.2.1.1 10.2.1.254 10.2.1.255 –10.2.2.0/24 10.2.2.1 10.2.2.254 10.2.2.255 – Etc. –10.2.255.0/24 10.2.255.1 10.2.255.254 10.2.255.255 10.3.0.0/16 Etc. 10.255.0.0/16 10.3.0.1 10.3.255.254 10.0.255.255 10.255.0.1 10.255.255.254 10.255.255.255 Rick Graziani graziani@cabrillo.edu 38 VLSM – Simple Example Subnets 10.0.0.0/16 10.1.0.0/16 10.2.0.0/16 10.2.0.0/24 10.2.1.0/24 10.2.2.0/24 Etc. 10.2.255.0/24 10.3.0.0/16 Etc. 10.255.0.0/16 • • • An example of VLSM, NOT of good network design. 10.1.0.0/16 10.2.0.0/24 10.2.1.0/24 10.7.0.0/16 10.3.0.0/16 10.2.6.0/24 10.4.0.0/16 10.2.3.0/24 10.2.8.0/24 10.5.0.0/16 10.8.0.0/16 10.2.5.0/24 10.6.0.0/16 10.2.4.0/24 Your network can now have 255 /16 subnets with 65,534 hosts each AND 256 /24 subnets with 254 hosts each. All you need to make it work is a classless routing protocol that passes the subnet mask with the network address in the routing updates. Classless routing protocols: RIPv2, EIGRP, OSPF, IS-IS, BGPv4 (coming) Rick Graziani graziani@cabrillo.edu 39 Another VLSM Example using /30 subnets 207.21.24.0/24 network subnetted into eight /27 (255.255.255.224) subnets 207.21.24.192/27 subnet, subnetted into eight /30 (255.255.255.252) subnets • • This network has seven /27 subnets with 30 hosts each AND eight /30 subnets with 2 hosts each. /30 subnets are very useful for serial networks. Rick Graziani graziani@cabrillo.edu 40 207.21.24.192/27 0 1 2 3 4 5 6 7 207.21.24.192/30 207.21.24.196/30 207.21.24.200/30 207.21.24.204/30 207.21.24.208/30 207.21.24.212/30 207.21.24.216/30 207.21.24.220/30 Rick Graziani graziani@cabrillo.edu 207.21.24. 11000000 /27 /30 207.21.24. 110 00000 207.21.24. 110 00100 207.21.24. 110 01000 207.21.24. 110 01100 207.21.24. 110 10000 207.21.24. 110 10100 207.21.24. 110 11000 207.21.24. 110 11100 Hosts Bcast 01 10 11 01 10 11 01 10 11 01 10 11 01 10 11 01 10 11 01 10 11 01 10 11 2 Hosts .193 & .194 .197 & .198 .201 & .202 .205 & .206 .209 & .210 .213 & .214 .217 & .218 .221 & .222 41 207.21.24.192/30 207.21.24.204/30 207.21.24.216/30 207.21.24.96/27 207.21.24.128/27 207.21.24.64/27 207.21.24.196/30 207.21.24.160/27 207.21.24.208/30 207.21.24.200/30 207.21.24.224/27 207.21.24.32/27 207.21.24.212/30 207.21.24.0/27 • This network has seven /27 subnets with 30 hosts each AND seven /30 • subnets with 2 hosts each (one left over). /30 subnets with 2 hosts per subnet do not waste host addresses on serial networks . Rick Graziani graziani@cabrillo.edu 42 VLSM and the Routing Table Displays one subnet mask for all child routes. Classful mask is assumed for the parent route. Routing Table without VLSM RouterX#show ip route 207.21.24.0/27 is subnetted, C 207.21.24.192 is directly C 207.21.24.196 is directly C 207.21.24.200 is directly C 207.21.24.204 is directly 4 subnets connected, connected, connected, connected, Serial0 Serial1 Serial2 FastEthernet0 Each child routes displays its own subnet mask. Classful mask is included for the parent route. Routing Table with VLSM RouterX#show ip route 207.21.24.0/24 is variably subnetted, 4 subnets, 2 masks C 207.21.24.192 /30 is directly connected, Serial0 C 207.21.24.196 /30 is directly connected, Serial1 C 207.21.24.200 /30 is directly connected, Serial2 C 207.21.24.96 /27 is directly connected, FastEthernet0 • Parent Route shows classful mask instead of subnet mask of the child routes. • Each Child Routes includes its subnet mask. Rick Graziani graziani@cabrillo.edu 43 Final Notes on VLSM • Whenever possible it is best to group contiguous routes together so • • they can be summarized (aggregated) by upstream routers. (coming soon!) – Even if not all of the contiguous routes are together, routing tables use the longest-bit match which allows the router to choose the more specific route over a summarized route. – Coming soon! You can keep on sub-subnetting as many times and as “deep” as you want to go. You can have various sizes of subnets with VLSM. Rick Graziani graziani@cabrillo.edu 44 Classful Routing Protocols • • • Classful Routing Protocols – RIPv1 – IGRP Classful routing protocols carry the network address in the routing update, but do not carry the subnet mask. Questions: – When receiving an routing update, how does the router know what mask to associate with the network address? – What if network address being sent in the update is subnet address, how does it determine the mask? Rick Graziani graziani@cabrillo.edu 45 Classful Routing Protocols Sending Routing Updates • Routing update includes only the: – Network address – Metric • If the routing update is being sent out of an interface with a different major network, then the update is summarized to the classful address. • There is no mask sent in routing updates from routers using classful routing protocols. Receiving Routing Updates • If routing update belongs to the same major network as the interface it is being received on, the subnet mask of the interface is applied to the network in the routing update. • If routing update belongs to a different major network than the interface it is being received on, the classful subnet mask of the network is applied to the network in the routing update. Rick Graziani graziani@cabrillo.edu 46 Classful Routing Protocols Sending/Receiving Subnet Routes • If routing update belongs to the same major network as the interface it is being received on, the subnet mask of the interface is applied to the network in the routing update. • SanJose1 sends out the routing update 172.30.3.0. • SanJose1 does not summarize this route to its classful address (172.30.0.0). • SanJose1 sends out the actual subnet address 172.30.3.0 because it is being sent out an interface Serial0, 172.30.2.2, which belongs to the same major network address as the update (172.30.0.0). Rick Graziani graziani@cabrillo.edu 172.30.3.0 47 Classful Routing Protocols Sending/Receiving Subnet Routes • If routing update belongs to the same major network as the interface it is being received on, the subnet mask of the interface is applied to the network in the routing update. • SanJose2 receives the routing update with the network address 172.30.3.0 on its Serial0 interface which has the address 172.30.3.1. • Because the update belongs to the same major network (172.30.0.0) as the receiving interface, SanJose2 applies the mask of the interface that it received the update on, /24. • The routing table process adds the network address 172.30.3.0, the /24 mask (255.255.255.0), and the appropriate metric to the routing table. Rick Graziani graziani@cabrillo.edu 172.30.3.0 New Route Added: 172.30.3.0 255.255.255.0 48 Classful Routing Protocols Sending/Receiving Routes over different Major Network • If routing update belongs to a different major network than the interface it is being received on, the classful subnet mask of the network is applied to the network in the routing update by the receiving router. • SanJose1 sends out the routing update 172.30.0.0. • SanJose1 summarizes the 172.30.3.0 route and any other subnets in its routing table that belong to the 172.30.0.0 network (172.30.1.0 and 172.30.2.0), to their major classful address (172.30.0.0). • SanJose1 sends out the summarized classful address 172.30.0.0 because it is being sent out an interface Serial1, 192.168.4.9, which belongs to a different major network address (192.168.4.8) than the update (172.30.0.0). Rick Graziani graziani@cabrillo.edu 172.30.0.0 49 Classful Routing Protocols Sending/Receiving Routes over different Major Network • If routing update belongs to a different major network than the interface it is being received on, the classful subnet mask of the network is applied to the network in the routing update by the receiving router. • • • Baypointe receives the routing update with the network address 172.30.0.0 on its Serial0 interface which has the address 192.168.4.10. Because the update (172.30.0.0) belongs to a different major network than the receiving interface (192.168.4.8), Baypointe applies the classful mask of the network address in the update, /16. The routing table process adds the network address 172.30.0.0, the /16 mask (255.255.0.0), and the appropriate metric to the routing table. Rick Graziani graziani@cabrillo.edu 172.30.0.0 New Route Added: 172.30.0.0 255.255.0.0 50 Classful Routing Protocols Issues with Classful Routing Protocols • Because the mask is derived from either the receiving interface (subnets within the same major network) or assumed as the classful mask (summarized networks between major networks), this limits addressing schemes that can be configured on these networks. Rick Graziani graziani@cabrillo.edu 172.30.3.0 172.30.0.0 51 Classful Routing Protocols Issues with Classful Routing Protocols • Because the network mask is not included with the network address in the routing update, networks that use Classful routing protocols cannot support: – VLSM – CIDR – Discontiguous Subnets • All of these require the receiving router to know the correct subnet mask. • CIDR – This is a summarized route, which also needs to have the mask included in the update. Rick Graziani graziani@cabrillo.edu 172.30.3.0 172.30.0.0 52 Classful Routing Protocols – No VLSM Subnets 10.0.0.0/16 10.1.0.0/16 10.2.0.0/16 10.2.0.0/24 10.2.1.0/24 10.2.2.0/24 Etc. 10.2.255.0/24 10.3.0.0/16 Etc. 10.255.0.0/16 An example of VLSM, NOT of good network design. 10.1.0.0/16 10.2.0.0/24 10.2.1.0/24 10.7.0.0/16 10.3.0.0/16 10.2.6.0/24 10.4.0.0/16 10.2.3.0/24 10.2.8.0/24 10.5.0.0/16 10.8.0.0/16 10.2.5.0/24 10.6.0.0/16 10.2.4.0/24 VLSM • For the same major network, there may be multiple masks. • Routers can no longer derive the mask from its own receiving interface. Rick Graziani graziani@cabrillo.edu 53 Classful Routing Protocols – No CIDR 200.199.48.0/25 200.199.56.0/23 CIDR These are summarized routes, which also need to have their masks included in the update. 200.199.48.0/25 200.199.49.0/25 200.199.56.0/23 11001000 11000111 0011 0000 00000000 11001000 11000111 0011 0001 00000000 11001000 11000111 0011 1000 00000000 200.199.48.0/20 11001000 11000111 0011 0000 00000000 20 bits in common Rick Graziani graziani@cabrillo.edu 54 Discontiguous subnets • • • • • Classful routing protocols, cannot support discontiguous subnets, because the subnet mask is not included in routing updates. Classful routing protocols automatically summarize on classful boundaries. SantaCruz1 and SantaCruz2 are both sending ISP the classful major network address of 172.30.0.0. ISP will apply the classful mask of /16, 255.255.0.0 to both routes. Both equal cost routes will be entered in the routing table and routing with unexpected and many times incorrect result will occur. Rick Graziani graziani@cabrillo.edu Internet 10.0.0.0/8 .1 e0 ISP .25 s0 s1 .21 192.168.4.24/30 172.30.2.0/24 .26 s0 Lo0 .1 SantaCruz1 .1 e0 172.30.1.0/24 192.168.4.20/30 s0 .22 Lo0 SantaCruz2 .1 172.30.110.0/24 .1 e0 172.30.100.0/24 55 Classful and Classless Routing Protocols RIPv1 and RIPv2 Classless routing protocols • The true defining characteristic of classless routing protocols is the • capability to carry subnet masks in their route advertisements. “One benefit of having a mask associated with each route is that the all-zeros and all-ones subnets are now available for use.” – Cisco allows the all-zeros and all-ones subnets to be used with classful routing protocols. Rick Graziani graziani@cabrillo.edu 57 Classless Routing Protocols Classless Routing Protocols: • RIPv2 • EIGRP • OSPF • IS-IS • BGPv4 Note: Remember classful/classless routing protocols is different than classful/classless routing behavior. Classlful/classless routing protocols (RIPv1, RIPv2, IGRP, EIGRP, OSPF, etc.) has to do with how routes get into the routing table; how the routing table gets built. Classful/classless routing behavior (no ip classless or ip classless) has to do with the lookup process of routes in the routing table (after the routing table has been built). It is possible to have a classful routing protocol and classless routing behavior or visa versa. It is also possible to have both a classful routing protocol and classful routing behavior; or both a classless routing protocol and classless routing behavior. Rick Graziani graziani@cabrillo.edu RIP version 1 • • • • Classful Routing Protocol, sent over UDP port 520 Does not include the subnet mask in the routing updates. Automatic summarization done at major network boundaries. Updates sent as broadcasts unless the neighbor command is uses which sends them as unicasts. 0 1 2 3 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | command (1) | version (1) | must be zero (2) | +---------------+---------------+-------------------------------+ | address family identifier (2) | must be zero (2) | +-------------------------------+-------------------------------+ | IP address (4) | +---------------------------------------------------------------+ | must be zero (4) | +---------------------------------------------------------------+ | must be zero (4) | +---------------------------------------------------------------+ | metric (4) | +---------------------------------------------------------------+ Rick Graziani graziani@cabrillo.edu RIP version 2 • • • • Classless Routing Protocol, sent over UDP port 520 Includes the subnet mask in the routing updates. Automatic summarization at major network boundaries can be disabled. Updates sent as multicasts unless the neighbor command is uses which sends them as unicasts. 0 1 2 3 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | command (1) | version (1) | must be zero (2) | +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ | Address Family Identifier (2) | Route Tag (2) | +-------------------------------+-------------------------------+ | IP Address (4) | +---------------------------------------------------------------+ | Subnet Mask (4) | +---------------------------------------------------------------+ | Next Hop (4) | +---------------------------------------------------------------+ | Metric (4) | +---------------------------------------------------------------+ Rick Graziani graziani@cabrillo.edu For more information on RIPv2 • • We will not discuss RIPv2 in detail except as an introduction into Classless Routing Protocols. We will do a lab regarding RIPv2, but for more information regarding RIPv2 see my PowerPoint presentation on my CCNP 1 web site: – Chapter 4 - RIP version 2 Rick Graziani graziani@cabrillo.edu 61 Ch. 1 – Introduction to Classless Routing CCNA 3 version 3.0 By Rick Graziani