Добавил:
Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:
Cisco Press CCNA ICND 2004 - Cisco Press.pdf
Скачиваний:
120
Добавлен:
24.05.2014
Размер:
13.19 Mб
Скачать

Miscellaneous TCP/IP Topics 283

Redirect ICMP Message

ICMP Redirect messages provide a very important element in routed IP networks. Many hosts are preconfigured with a default router IP address. When sending packets destined for subnets other than the one to which they are directly connected, these hosts send the packets to their default router. If there is a better local router to which the host should send the packets, an ICMP redirect can be used to tell the host to send the packets to this different router.

For example, in Figure 8-14, the PC uses Router B as its default router. However, Router A’s route to subnet 10.1.4.0 is a better route. (Assume the use of mask 255.255.255.0 in each subnet in Figure 8-14.) The PC sends a packet to Router B (Step 1 in Figure 8-14). Router B then forwards the packet based on its own routing table (Step 2); that route points through

Router A, which has a better route. Finally, Router B sends the ICMP redirect message to the PC

(Step 3), telling it to forward future packets destined for 10.1.4.0 to Router A instead. Ironically, the host can ignore the redirect and keep sending the packets to Router B, but in this example, the PC believes the redirect message, sending its next packet (Step 4) directly to Router A.

Figure 8-14 ICMP Redirect

A

Subnet 10.1.4.0

Packet

2

Packet 1 2

4 1

B

 

 

3 Redirect

Packet

1

 

 

 

 

 

ICMP Redirect

 

— Use Router A

Host

In summary, ICMP defines several message types and several subtypes. RFC 792 is a short and straightforward RFC to read if you want more information.

Secondary IP Addressing

Imagine that you planned your IP addressing scheme for a network. Later, a particular subnet grows, and you have used all the valid IP addresses in the subnet. What should you do? You could change the mask used on that subnet, making the existing subnet larger. However, changing the mask could cause several problems. For instance, if 10.1.4.0/24 is running out of addresses, and you make a change to mask 255.255.254.0 (9 host bits, 23 network/subnet bits), the new subnet includes addresses 10.1.4.0 to 10.1.5.255. If you have already assigned subnet 10.1.5.0/24, with assignable addresses 10.1.5.1 through 10.1.5.254, you would create an overlap, which is not allowed.

284 Chapter 8: Advanced TCP/IP Topics

You could change all the IP addresses in the constrained network, replacing the original addresses with addresses from a new, larger subnet. However, this solution requires administrative effort to change the IP addresses.

Both of these solutions imply a strategy of using different masks in different parts of the network. Use of these different masks is called variable-length subnet masking (VLSM), which brings up another set of complex routing protocol issues.

The router needs to have more than one IP address on the interface attached to that medium. Secondary addressing provides yet another solution to the problem of running out of addresses in a subnet. Secondary addressing uses multiple networks or subnets on the same data link. The concept is simple: By using more than one subnet on the same medium you increase the number of available IP addresses. For example, Figure 8-15 has subnet 10.1.2.0/

24; assume that it has all IP addresses assigned. Assuming secondary addressing to be the chosen solution, subnet 10.1.7.0/24 also could be used on the same Ethernet. Example 8-5 shows the configuration for secondary IP addressing on Yosemite.

Figure 8-15 TCP/IP Network with Secondary Addresses

Bugs Daffy

10.1.1.0

10.1.1.251

10.1.128.251

10.1.128.252

s0

s0

 

 

0

 

.

 

.128

 

 

1

 

.

 

10

 

 

Albuquerque

 

s1

10.1.130.251

 

10

 

 

.

 

 

1

 

 

.

 

 

130

10.1.130.253

 

0

 

.

 

 

 

s0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

10.1.129.0

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Yosemite

 

 

 

 

 

s1

 

 

 

 

 

s1

 

 

 

Seville

 

 

 

 

10.1.129.252

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

10.1.129.253

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

10.1.3.253

Primary

10.1.2.0

 

 

 

10.1.7.0

 

 

 

 

 

 

 

 

 

 

10.1.3.0

10.1.2.252,

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Secondary

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

10.1.7.252

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Sam

Emma

Elmer

Red