Routing Information Protocol

RIP is a widely used interior routing protocol. It is included as part of the operating system with many Linux and Unix systems, as well as in the Windows NT/2000 RRAS package. RIP is installed on many systems, and it is easy to configure and run.

RIP defines the "best" route as being the lowest-cost route, which is the one with the lowest routing metric. The routing metric is an arbitrary number from 1 to 15 that represents the number of gateways that traffic must pass through to reach the destination. RIP calls each router a "hop" and the metric a "hop count." The best route to a destination is the one that passes through the fewest routers. This technique for determining the best route is called a distance-vector algorithm.

When RIP starts, it broadcasts a request for routing information. A router running RIP responds to the request by sending an update packet that contains the destination addresses and associated metrics from its routing table. In addition to responding to requests, routers that run RIP issue update packets every 30 seconds. If a router stops issuing updates for 180 seconds, the other routers on the network assume that it is dead, and delete any routes that go through that router.

RIP processes an update packet in the following manner:

• If the packet contains new routes that are not in the routing table, they are added.

• If the packet contains routes that are lower cost than the same routes in the existing routing table, the old routes are deleted, and the new routes are used. The cost of a new route is determined by adding the cost of reaching the router that sent the update to the cost metric included in the update packet.

• If the packet contains routes that have a cost of 15, those routes are deleted from the routing table if the update came from the gateway used for those routes. For example, if your routing table contains a route to subnet 172.16.50.0 through gateway 172.16.55.36 and it receives a RIP update from 172.16.55.36 with a cost of 15 for the route to 172.16.50.0, your system deletes the route.

RIP has been around for a long time, and it shows its age. Very large networks cannot use RIP because the longest route it allows is 15 hops. This should be large enough for your network, but it is insufficient for large national networks. Additionally, it can take a long time for the routing table to reflect the current state of the network because RIP waits 180 seconds before discarding routes from an inactive router. This can be worsened by the "count to infinity" problem. (Not familiar with "counting to infinity?" See the upcoming sidebar.) More important than either of these problems is the fact that RIP is not equipped to handle network bit masks, which makes it incompatible with current IP address standards.

Counting to Infinity

A problem with the original RIP design is something known as "counting to infinity." Let's use Figure 7.2 to illustrate this problem.

Router B advertises finch as being two hops away because it reaches finch through A. C advertises finch as being three hops away because it reaches it through B. Assume that router A crashes. B no longer gets updates from A, so it doesn't think it can reach finch through A. However, it does see an update from C, saying that finch is three hops away. So B updates its routing table, and now advertises finch as being four hops away. Because C reaches finch through B, it updates its routing table and advertises finch as being five hops away. B then sees the update from C and changes its routing table. This goes on and on until we reach infinity. Luckily, infinity is only 15 for a RIP hop count.

RIP addresses this problem in three ways: split horizon, poison reverse, and triggered updates. The split horizon rule says that a router never advertises a route on the network from which it learned the route. Therefore, C would not advertise that it could reach finch to B because it learned the route from B.

Poison reverse takes this one step further. It says that a router should advertise an infinite distance for a route on the network from which it learned the route. Thus, C would tell B that it cannot reach finch by advertising a hop count of 15 for the route to finch.

With triggered updates, changes to the routing table are immediately advertised instead of waiting the normal 30-second interval between RIP updates. Therefore, even when a count-to-infinity problem does occur, it only takes as long as it takes for the routers to exchange 15 packets. Without triggered updates, counting to infinity can take several minutes.

Split horizon, poison reverse, and triggered updates have effectively eliminated the count-to-infinity problem in RIP. However, they do not address the other problems with RIP. To address those problems, the new routing protocols described next have been developed.

Was this article helpful?

0 0

Post a comment