IP Routing Protocols

IP routing protocols fill the IP routing table with valid, (hopefully) loop-free routes. Each route includes a subnet number, the interface out which to forward packets so that they are delivered to that subnet, and the IP address of the next router that should receive packets destined for that subnet (if needed).

Before examining the underlying logic, you need to consider the goals of a routing protocol. The goals described in the following list are common for any IP routing protocol, regardless of its underlying logic type:

■ To dynamically learn and fill the routing table with a route to all subnets in the network.

■ If more than one route to a subnet is available, to place the best route in the routing table.

■ To notice when routes in the table are no longer valid, and to remove those routes from the routing table.

■ If a route is removed from the routing table and another route through another neighboring router is available, to add the route to the routing table. (Many people view this goal and the preceding one as a single goal.)

■ To add new routes, or to replace lost routes, with the best currently available route as quickly as possible. The time between losing the route and finding a working replacement route is called convergence time.

■ To prevent routing loops.

Routing protocols can become rather complicated, but the basic logic that they use is relatively simple. Routing protocols take the routes in a routing table and send a message to their neighbors telling them about the routes. After a while, everyone has heard about all the routes.

Figure 5-14 shows a sample network, with routing updates shown. Table 5-6 lists Router B's routing table before receiving the routing updates, and Table 5-7 lists Router B's routing table after receiving the routing updates.

Figure 5-14 Router A Advertising Routes Learned from Router C

162.11.5.0

Router A

162.11.8.1

Routing Update

162.11.10.0

2

162.11.5.0

1

162.11.9.0

Figure 5-14 Router A Advertising Routes Learned from Router C

162.11.5.0

Router A

162.11.8.1

162.11.8.0

Router B

162.11.10.0

162.11.7.0

Router B

162.11.10.0

162.11.7.0

Table 5-6 Router B Routing Table Before Receiving the Update Shown in Figure 5-14

Group

Outgoing Interface

Next-Hop Router

Metric

Comments

162.11.7.0

E0

0

This is a directly connected route.

162.11.8.0

S0

0

This is a directly connected route.

Table 5-7 Router B Routing Table After Receiving the Update Shown in Figure 5-14

Group

Outgoing Interface

Next-Hop Router

Metric

Comments

162.11.5.0

S0

162.11.8.1

1

Learned from Router A, so next-hop is Router A.

162.11.7.0

E0

0

This is a directly connected route.

162.11.8.0

S0

0

This is a directly connected route.

162.11.9.0

S0

162.11.8.1

1

Learned from Router A, so next-hop is Router A.

162.11.10.0

S0

162.11.8.1

2

This one was learned from Router A, which learned it from Router C.

Router B adds routes for directly connected subnets when the interfaces first initialize. In fact, no routing protocols are needed for a router to learn routes to the directly connected subnets. So, before Router B receives any routing updates, it knows about only two routes—the two connected routes—as listed in Table 5-6.

After receiving the update from Router A, Router B has learned three more routes. Because Router B learned those routes from Router A, all three of B's routes point back to Router A as the next hop router. That makes sense because it is obvious from the figure that B's only path to the other subnets lies through Router A.

Router A learned about subnets 162.11.5.0 and 162.11.9.0 because A is connected directly to those subnets. Router A, in turn, learned about subnet 162.11.10.0, the subnet off Router C's Ethernet, from routing updates sent by Router C.

0 0

Post a comment