1 managing ip addresses and broadcasts chapter 2
TRANSCRIPT
22
Making Networks Scalable
A scalable network grows continually, yet smoothly and stably
Avoid problems with growing networks by providing redundancy and designing networks for easy manageability
Choice of routing protocol greatly influences scalability of network
33
The Growth of the Internet
Initially, Internet was small and limited to researchers
In 1990s, Internet grew immensely as governments, universities, corporations, and the general public began to use it
Organizations and Internet now experiencing problems managing IP addresses
44
IP Address Exhaustion
32-bit IP addresses provide, in theory, over four billion addressesMany allocated addresses are wasted
Fear that the Internet may run out of usable IP addresses
55
Wasting Addresses
It is acceptable to use subnet zero and the all-ones subnet with VLSM.(In the past, use of the first and last subnets was discouraged).
Consider the following example:
In this network a Class C address with a 255.255.255.0 mask has been used for each subnet
192.168.1.0/24
192.168.2.0/24
192.168.3.0/24
The WAN link has enough IP addresses for 254 separate hosts, but will use only two. Each LAN has enough IP addresses for 254 separate hosts. Broadcasts would be a major issue if this address space were not further subnetted.
Consider this alternative addressing scheme:
192.168.0.0/25 192.168.0.128/26
192.168.0.192/30
This network allows 126 different host addresses
This network allows 62 different host addressesThis network allows just
2 host addresses
66
Routing Table Growth
Internet routing table increased from about 5000 routers in 1990 to more than 100,000 in 2001
Large routing tables require more CPU time and more memoryResult in slowed down table lookupsMake troubleshooting more difficult
77
Managing IP Addresses
Administrators use many strategies to manage IP addresses
Hierarchical addressing Hierarchical routing Route summarization Variable-length subnet masks Classful and classless routing
88
Hierarchical Addressing
Layered, orderly addressing Similar to public telephone network
Local office recognizes local exchangeLocal central office forwards long distance
calls to central office in other area codesCalls then treated as local call by
central office in other area codes
99
Hierarchical Routing
• Router forwards packet to core layer router based on first octet IP address
• Core layer router forwards packet to distribution layer router based on first two octets
• Distribution layer router forwards packet to access layer router based on first three octets
• Access layer router forwards packet to final destination
1010
Route Summarization
Also called address aggregation Combines multiple routes that share
leftmost bits into one summary routeSimilar to telephone area code
Reduces number of routes to a specific customer
1212
Route Summarization
• If router has both summary route and ordinary route, it selects the one with the longest matchLooks at length of prefix or number of bits in
subnet mask to determine path• Route summarization does not make
address allocation more efficient, especially point-to-point links
1616
Variable-Length Subnet Masks
VLSMs, defined in RFC 1812, let you subdivide Class C
Subnet mask helps router break IP address into network and host portions Router uses network part of IP address to
forward packet to correct networkLocal router uses host part of IP address to
deliver packet to destination
1818
The Logical AND Operation
• Router matches bits in IP address and subnet mask
• Compares bits and performs logical AND operation If both bits are ones, the result is a one If either bit is a zero, the result is a zero
• Logical AND operation provides network number
2020
Calculating Subnets
Number of subnets depends on number of bits borrowed from network portion of IP address
Calculate number of new subnets by 2n, where n is the number of borrowed bitsSubtract two to find number of usable host bits First and last addresses reserved for network
address and broadcast address
2121
Classful and Classless Netmasks
If netmask follows traditional class boundaries, it is called classful routing
If netmask does not follow traditional class boundaries, it is called classless routingCan supernet or use a smaller netmask than
traditional class boundaries
2222
Example: Calculating Subnets with VLSM
28 hosts
60 hosts 12 hosts 12 hosts
A class C address of 192.168.10.0/24 has been allocated.
Requirement levels, listed from the largest to the smallest:
Host address range
Singapore to KL
Sydney to KL
Perth to KL
12Singapore
12Sydney
28KL LAN
60Perth LAN
4th Octet network/host bitsHostsNetwork
192.168.10.0/26
192.168.10.64/27
192.168.10.96/28 192.168.10.112 /28
192.168.10.128 /30
192.168.10.132 /30
192.168.10.136 /30
2
2
2
.NNHHHHHH /26 ( 62 hosts) 192.168.10.1 - 192.168.10.62
.NNNHHHHH /27 ( 30 hosts) 192.168.10.65 - 192.168.10.94
.NNNNHHHH /28 ( 14 hosts) 192.168.10.97 - 192.168.10.110
.NNNNHHHH /28 ( 14 hosts) 192.168.10.113 - 192.168.10.126
.NNNNNNHH /30 (2 hosts) 192.168.10.129 - 192.168.10.130
.NNNNNNHH /30 (2 hosts) 192.168.10.133 - 192.168.10.134
.NNNNNNHH /30 (2 hosts) 192.168.10.137 - 192.168.10.138
2323
Calculating VLSM Subnet Masks
According to RFC 1812, all bits in subnet mask must be contiguousCisco IOS displays error message if subnet has
discontiguous bits Be sure routing protocol supports VLSMs
OSPF and EIGP support VLSMsRIP version 1 and IGRP do not support VLSMs
2525
Summarizing Routes Using VLSMs• VLSMs allocate IP addresses more
efficiently• VLSMs provide more flexibility in
summarizing routes Based entirely on higher-order bits they share
on the leftRoutes do not have to be contiguousPrefix of summary route based on bits shared
by all routes
2828
Example: Route Aggregation with VLSM
200.199.62.0 /25200.199.62.128/25200.199.63.0 /25200.199.63.128/25
200.199.48.0/24200.199.49.0/24200.199.50.0/24200.199.51.0/24
200.199.32.0/22200.199.36.0/22200.199.40.0/22200.199.44.0/22
Advertise one supernet route: _______________ to RTZ
Advertise one supernet route: _______________ to RTZ
Advertise one supernet route: _______________ to RTZ
Advertise one supernet route: _______________ to ISP
200.199.62.0/23
200.199.48.0/22
200.199.32.0/19
200.199.32.0/20
2929
Classes of IP Addresses
Class depends on first octet of IP addressClass A addresses begin with a zero as the leftmost
bit; use 8 bits for network addressClass B addresses begin with a 10 as the first two
bits; use 16 bits for network addressClass C addresses begin with a 110 as the first
three bits; use 24 bits for network addressClass D addresses are used for multicastClass E addresses are used for research
3030
Classful Routing
Router uses classes of addressesCan subnet along class octet boundaries
Routing protocols include RIPv1 and IGRPMay use IP classless global configuration
command to forward packets to a summary route
Classful routing is inflexible, limited, and sometimes wasteful
3232
Classless Routing Ignores traditional class boundaries Protocols include OSPF and EIGRP
Can allocate and receive IP addresses as necessary Previously Three Regional Internet Registries (RIRs)
now Five, allocate IP classless addresses in blocks American Registry for Internet Numbers (ARIN) Réseaux IP Européens Network Coordination Centre
(RIPE NCC) Asia Pacific Network Information Center (APNIC) Regional Latin-America and Caribean Address Registry
(LACNIC)-2002 African Network Information Centre (AfriNIC)-2005
3333
Classless Inter-Domain Routing (CIDR)
RIRs assign addresses based on Classless Inter-Domain Routing (CIDR)CIDR discussed in RFCs 1518, 1519, and
2050 Each CIDR block has a prefix or IP
address and a prefix length or subnet mask
3434
Allocating IP Addresses
How IP addresses are allocated affects how well network performs
Pitfalls of route summarizationRequires more planningMore useful with classless routing protocolCan lead to poor path selectionCan create problem with discontiguous subnets
3535
Problems with Summarization and Discontiguous Subnets
Route summarization hides details of network from routers
Discontiguous subnets may result in outage or inability to deliver packets
3838
Allocating IP Addresses Using VLSMs
• Efficient allocation of IP addresses requires Allocating enough IP addresses to each subnet for
future growth Not allocating more than necessary for each subnet
• Plan for route summarization Do not assign IP addresses haphazardly Assign IP addresses based on topology
of network
4040
Process of Assigning IP Addresses
After finding baseline subnet, calculate the number of subnets you can useCisco recommends allocating addresses from
the lowest to the highest for easier summarizing of routes
Put your largest networks into the lower subnets
4141
Other Addressing Strategies
Unnumbered interfaces Private address space Network address translation IP version 6
4242
Unnumbered Interfaces
• Configure IP on interface without explicitly using an IP address Use ip unnumbered command to refer to an existing
interface that routers use as source address Unnumbered interfaces often get IP address from
loopback address• Drawbacks include inability to get status by pinging,
making troubleshooting and monitoring more difficult• Some serial protocols such as X.25 and SMDS do
not support unnumbered interfaces
4343
Private Address Space
RCF 1918 sets aside three ranges of IP addresses for private networks 10.0.0.0/8192.168.0.0/16172.16.0.0 through 172.31.255.255
Do not route addresses in these blocks to the Internet
4444
Network Address Translation
• NAT involves device such as a router that translates one set of IP addresses into another setCan conserve IP addresses by translating a large
pool of private addresses into a small pool of public addresses
• Disadvantages include increased latency and difficulties with protocols or applications that put IP address in data portion of IP packet
4545
IP Version 6
IPv6, specified in RFC 2460, offers several advantages over current version (IPv4)Uses 128 bit IP addressesProvide over 3 x 1038 possible IP addresses Includes more support for quality of service
and better security Adoption of IPv6 is moving slowly
4646
Managing Broadcasts
Routers do not, by default, forward broadcasts If PC boots without knowing its IP address, it
must contact DHCP or BOOTP server If server not on same segment, PC cannot get an IP
addressCan hard code all IP addresses if PC unable to
reach server Creates administrative nightmare
4747
Using a Helper Address Solution is to allow broadcasts in specific
situations Cisco routers can direct a broadcast to a helper
address Can configure more than one helper address Must use IP directed-broadcast interface
configuration command with Cisco IOS 12.0 and later
Configure helper address to router closest to client By default, helper address command turns on eight
UDP ports as shown in Table 2-8