Quản trị mạng - Chapter 6: Vlsm and cidr

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

pdf52 trang | Chia sẻ: nguyenlam99 | Lượt xem: 873 | Lượt tải: 0download
Bạn đang xem trước 20 trang tài liệu Quản trị mạng - Chapter 6: Vlsm and cidr, để xem tài liệu hoàn chỉnh bạn click vào nút DOWNLOAD ở trên
Chapter 6: VLSM and CIDR CCNA Exploration version 4.0 Học viện mạng Bách Khoa - Website: www.bkacad.com 2 Objectives • Compare and contrast classful and classless IP addressing. • Review VLSM and explain the benefits of classless IP addressing. • Describe the role of the Classless Inter-Domain Routing (CIDR) standard in making efficient use of scarce IPv4 addresses Học viện mạng Bách Khoa - Website: www.bkacad.com 3 Introduction • Prior to 1981, IP addresses used only the first 8 bits to specify the network portion of the address • In 1981, RFC 791 modified the IPv4 32-bit address to allow for three different classes • IP address space was depleting rapidly – The Internet Engineering Task Force (IETF) introduced Classless Inter-Domain Routing (CIDR) – CIDR uses Variable Length Subnet Masking (VLSM) to help conserve address space. 1. VLSM is simply subnetting a subnet 2. Subnets can be further subnetted in multiple levels 3. In addition to subnetting, it became possible to summarize a large collection of classful networks into an aggregate route, or supernet. Học viện mạng Bách Khoa - Website: www.bkacad.com 4 Classful and Classless Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 5 • As of January 2007, there are over 433 million hosts on internet Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 6 • Initiatives to conserve IPv4 address space include: 1. VLSM & CIDR notation (1993, RFC 1519) 2.Network Address Translation (1994, RFC 1631) 3. Private Addressing (1996, RFC 1918) Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 7 Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 8 • Classes of IP addresses are identified by the decimal number of the 1st octet – Class A address begin with a 0 bit • Range of class A addresses 0.0.0.0 to 127.255.255.255 – Class B address begin with a 1 bit and a 0 bit • Range of class B addresses 128.0.0.0 to 191.255.255.255 – Class C addresses begin with two 1 bits & a 0 bit • Range of class C addresses 192.0.0.0 to 223.255.255.255 Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 9 • The IPv4 Classful Addressing Structure (RFC 790) • An IP address has 2 parts: – The network portion: the left side of an IP address – The host portion: the right side of an IP address Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 10 Classful IP Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 11 Classful Routing Protocol Học viện mạng Bách Khoa - Website: www.bkacad.com 12 • Recall that classful routing protocols (i.e. RIPv1) do not send subnet masks in their routing updates – Router receives the routing update could determine the subnet mask simply by examining the value of the first octet in the network address, or by applying its ingress interface mask for subnetted routes. – The reason is that the Subnet mask is directly related to the network address Classful Routing Protocol Học viện mạng Bách Khoa - Website: www.bkacad.com 13 Classful Routing Protocol • Convergence ? R1 R2 Học viện mạng Bách Khoa - Website: www.bkacad.com 14 Extra: The problems of IP v4 1. Exhaustion of the Class B network address space. One fundamental cause of this problem is the lack of a network class of a size that is appropriate for mid-sized organization. • Class C is too small, whereas Class B is too large for most organizations but was the best fit available for use with subnetting. 2. Growth of routing tables in Internet routers beyond the ability of current software, hardware, and people to effectively manage. 3. Eventual exhaustion of the 32-bit IPv4 address space. Học viện mạng Bách Khoa - Website: www.bkacad.com 15 Extra: The problems of IP v4 • The design and deployment of CIDR was intended to solve these problems by providing a mechanism to slow the growth of global routing tables and to reduce the rate of consumption of IPv4 address space. • It did not and does not attempt to solve the third problem. • Học viện mạng Bách Khoa - Website: www.bkacad.com 16 Classless IP Addressing • Classless Inter-domain Routing (CIDR – RFC 1517). Allows for: –More efficient use of IPv4 address space –Prefix aggregation, which reduced the size of routing tables (route summarization ) • Requires subnet mask to be included in routing update because address class is meaningless Học viện mạng Bách Khoa - Website: www.bkacad.com 17 •CIDR uses Variable Length Subnet Masks (VLSM) to allocate IP addresses to subnets according to individual need rather than by class. CIDR and Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 18 • CIDR allowed for prefix aggregation, which you already know as route summarization. • A supernet summarizes multiple network addresses with a mask less than the classful mask. • Propagating VLSM and supernet routes requires a classless routing protocol, because the subnet mask can no longer be determined by the value of the first octet. CIDR and Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 19 CIDR and Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 20 Classless Routing Protocol • Characteristics of classless routing protocols: –Routing updates include the subnet mask –Supports VLSM –Supports Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 21 Classless Routing Protocol Routing Protocol Routing updates Include subnet Mask Supports VLSM Ability to send Supernet routes Classful No No No Classless Yes Yes Yes Học viện mạng Bách Khoa - Website: www.bkacad.com 22 Classless Routing Protocol • Note: – Classful routing protocols cannot send supernet routes because the receiving router will apply the default classful to the network address in the routing update. – When a supernet route is in a routing table, for example, as a static route, a classful routing protocol will not include that route in its updates. R1(config)# ip route 172.0.0.0 255.0.0.0 loopback1 RT: S 172.0.0.0/8 Học viện mạng Bách Khoa - Website: www.bkacad.com 23 Classful Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 24 Subnetting Học viện mạng Bách Khoa - Website: www.bkacad.com 25 Classless Addressing Học viện mạng Bách Khoa - Website: www.bkacad.com 26 VLSM Học viện mạng Bách Khoa - Website: www.bkacad.com 27 • Classful routing –Only allows for one subnet mask for all networks • VLSM & classless routing –This is the process of subnetting a subnet –More than one subnet mask can be used • Animation 6.2.1 VLSM in Action Học viện mạng Bách Khoa - Website: www.bkacad.com 28 VLSM in Action Học viện mạng Bách Khoa - Website: www.bkacad.com 29 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.32/27 207.21.24.64/27 207.21.24.96/27 207.21.24.128/27 207.21.24.160/27 207.21.24.224/27 207.21.24.0/27 207.21.24.216/30 • 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 . Học viện mạng Bách Khoa - Website: www.bkacad.com 30 VLSM and the Routing Table Routing Table without VLSM RouterX#show ip route 207.21.24.0/27 is subnetted, 4 subnets C 207.21.24.0 is directly connected, Serial0 C 207.21.24.32 is directly connected, Serial1 C 207.21.24.64 is directly connected, Serial2 C 207.21.24.96 is directly connected, FastEthernet0 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. Displays one subnet mask for all child routes. Classful mask is assumed for the parent route. Each child routes displays its own subnet mask. Classful mask is included for the parent route. Học viện mạng Bách Khoa - Website: www.bkacad.com 31 • VLSM – the process of sub-netting a subnet to fit your needs • Example: – Subnet 10.1.0.0/16, 8 more bits are borrowed again, to create 256 subnets with a /24 mask. – Mask allows for 254 host addresses per subnet – Subnets range from: 10.1.0.0 / 24 to 10.1.255.0 / 24 VLSM Học viện mạng Bách Khoa - Website: www.bkacad.com 32 VLSM Học viện mạng Bách Khoa - Website: www.bkacad.com 33 All Zeros and All Ones Subnets Using the All Ones Subnet • There is no command to enable or disable the use of the all-ones subnet, it is enabled by default. • 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. Router(config)#ip subnet-zero 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 0080093f18.shtml Học viện mạng Bách Khoa - Website: www.bkacad.com 34 CIDR Học viện mạng Bách Khoa - Website: www.bkacad.com 35 Học viện mạng Bách Khoa - Website: www.bkacad.com 36 • Route summarization done by CIDR – Routes are summarized with masks that are less than that of the default classful mask – Example: 172.16.0.0 / 13 is the summarized route for the 172.16.0.0 / 16 to 172.23.0.0 / 16 classful networks Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 37 Route Summarization Học viện mạng Bách Khoa - Website: www.bkacad.com 38 Calculating Route Summarization • Steps to calculate a route summary – List networks in binary format – Count number of left most matching bits to determine summary route’s mask – Copy the matching bits and add zero bits to determine the summarized network address Học viện mạng Bách Khoa - Website: www.bkacad.com 39 Without CIDR, a router must maintain individual routing table entries for these class B networks. With CIDR, a router can summarize these routes into eight networks by using a 13-bit prefix: 172.24.0.0 /13 1. Count the number of left-most matching bits, /13 2. Add all zeros after the last matching bit: 172.24.0.0 = 10101100 00011000 00000000 00000000 Steps: Học viện mạng Bách Khoa - Website: www.bkacad.com 40 CIDR (Classless Inter-Domain Routing) 1.More efficient routing – reduced routing table size – reduced routing update traffic 2. A reduced number of CPU cycles when recalculating a routing table, or when sorting through the routing table entries to find a match 3. Reduced router memory requirements Học viện mạng Bách Khoa - Website: www.bkacad.com 41 CIDR (Classless Inter-Domain Routing) •Route summarization is also known as: –Route aggregation –Supernetting •Supernetting is essentially the inverse of subnetting. Học viện mạng Bách Khoa - Website: www.bkacad.com 42 • 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 23 bits in common Supernetting Example Học viện mạng Bách Khoa - Website: www.bkacad.com 43 • 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. Supernetting Example Học viện mạng Bách Khoa - Website: www.bkacad.com 44 CIDR and the Provider Học viện mạng Bách Khoa - Website: www.bkacad.com 45 200.199.48.0/24 11001000 11000111 001100 00 00000000 200.199.49.0/24 11001000 11000111 001100 01 00000000 200.199.50.0/24 11001000 11000111 001100 10 00000000 200.199.51.0/24 11001000 11000111 001100 11 00000000 200.199.48.0/22 11001000 11000111 001100 00 00000000 200.199.52.0/24 11001000 11000111 001101 00 00000000 200.199.53.0/24 11001000 11000111 001101 01 00000000 200.199.54.0/24 11001000 11000111 001101 10 00000000 200.199.55.0/24 11001000 11000111 001101 11 00000000 200.199.52.0/22 11001000 11000111 001101 00 00000000 200.199.56.0/24 11001000 11000111 00111 000 00000000 200.199.57.0/24 11001000 11000111 00111 001 00000000 .. 200.199.63.0/24 11001000 11000111 00111 111 00000000 200.199.56.0/21 11001000 11000111 00111 000 00000000 CIDR and the provider Học viện mạng Bách Khoa - Website: www.bkacad.com 46 • Dynamic routing protocols must send network address and mask (prefix-length) information in their routing updates. • In other words, CIDR requires classless routing protocols for dynamic routing. CIDR Restrictions Học viện mạng Bách Khoa - Website: www.bkacad.com 47 Route flapping Học viện mạng Bách Khoa - Website: www.bkacad.com 48 Extra: Configure a route aggregation with RIP version2 S0/0 RTA(config)#router rip ver 2 no auto-summary RTA(config)#int s0/0 ip summary-address rip 200.199.48.0 255.255.252.0 Học viện mạng Bách Khoa - Website: www.bkacad.com 49 • RTA(config)#router rip • ver 2 • no auto-summary • RTA(config)#int s0/0 • ip summary-address rip 200.199.48.0 255.255.252.0 Học viện mạng Bách Khoa - Website: www.bkacad.com 50 Labs Học viện mạng Bách Khoa - Website: www.bkacad.com 51 Summary Học viện mạng Bách Khoa - Website: www.bkacad.com 52

Các file đính kèm theo tài liệu này:

  • pdfca_ex_s2m06_vlsm_and_cidr_975_7901.pdf
Tài liệu liên quan