Please Whitelist This Site?

I know everyone hates ads. But please understand that I am providing premium content for free that takes hundreds of hours of time to research and write. I don't want to go to a pay-only model like some sites, but when more and more people block ads, I end up working for free. And I have a family to support, just like you. :)

If you like The TCP/IP Guide, please consider the download version. It's priced very economically and you can read all of it in a convenient format without ads.

If you want to use this site for free, I'd be grateful if you could add the site to the whitelist for Adblock. To do so, just open the Adblock menu and select "Disable on tcpipguide.com". Or go to the Tools menu and select "Adblock Plus Preferences...". Then click "Add Filter..." at the bottom, and add this string: "@@||tcpipguide.com^$document". Then just click OK.

Thanks for your understanding!

Sincerely, Charles Kozierok
Author and Publisher, The TCP/IP Guide


NOTE: Using software to mass-download the site degrades the server and is prohibited.
If you want to read The TCP/IP Guide offline, please consider licensing it. Thank you.

The Book is Here... and Now On Sale!

The whole site in one document for easy reference!
The TCP/IP Guide

Custom Search







Table Of Contents  The TCP/IP Guide
 9  TCP/IP Lower-Layer (Interface, Internet and Transport) Protocols (OSI Layers 2, 3 and 4)
      9  TCP/IP Internet Layer (OSI Network Layer) Protocols
           9  TCP/IP Routing Protocols (Gateway Protocols)
                9  TCP/IP Interior Routing Protocols (RIP, OSPF, GGP, HELLO, IGRP, EIGRP)
                     9  TCP/IP Routing Information Protocol (RIP, RIP-2 and RIPng)
                          9  RIP Fundamentals and General Operation

Previous Topic/Section
RIP Overview, History, Standards and Versions
Previous Page
Pages in Current Topic/Section
1
2
3
Next Page
RIP General Operation, Messaging and Timers
Next Topic/Section

RIP Route Determination Algorithm and Metric
(Page 2 of 3)

RIP Route Determination and Information Propagation Example

Let's take a specific example to help us understand better how routes are determined using RIP. Consider a relatively simple internetwork with four individual networks, connected as follows:

  • Router A (RA) connects Network 1 (N1) to Network 2 (N2).

  • Routers B (RB) and C (RC) connect Network 2 to Network 3 (N3).

  • Router D (RD) connects Network 3 to Network 4 (N4).

This example autonomous system is illustrated in Figure 172.


Figure 172: Example RIP Autonomous System

This is an example of a simple autonomous system that contains four physical networks and four routers.

 


Now, let's suppose that we just turned on router RA. It sees that it is directly connected to N1 and N2, so it will have an entry in its routing table indicating that it can reach N1 at a cost of 1, which we can represent as {N1,1}. Information about Network 1 will propagate from Router RA across the internetwork in the following sequence of steps (which you can observe graphically in Figure 173):

  1. Router A sends out an RIP message containing the entry {N1,1} on each of the networks to which it is connected. There are no other routers on N1, so nothing happens there. But RB and RC are on N2 so they receive the information.

  2. RB and RC will look in their routing tables to see if they already have entries for N1. Assuming neither does, they will each create a routing table entry {N1,2} for Router A. This means “I can reach Network 1 at a cost of 2 hops by sending to Router A”.

  3. RB and RC will each send their own routing tables out over the networks to which they are connected: N2 and N3. This will contain the entry {N1,2}. RA will receive that message on N2 but will ignore it, since it knows it can reach N1 directly (cost of 1, which is less than 2). But Router D will receive the message on N3.

  4. RD will examine its routing table, and seeing no entry for N1 will add the entry {N1,3} for RB or RC. Of course, either one will work, so which is chosen depends entirely on whether RD received information about N1 first from RB or RC.

  5. RD will send the entry {N1,3} on Network 4, but of course there are no other routers there to hear it.

    Figure 173: Propagation of Network Routing Information Using RIP

    This composite diagram illustrates the five steps in propagating route information about network N1 from RA to the rest of the autonomous system. In Step #1 the information is sent from RA to both of its connected networks. In Step #2 it reaches routers RB and RC, which then know they can reach N1 through RA at a cost of one additional hop. In Step #3 these two routers send this information on their networks, and in Step #4 it reaches RD. In Step #5 RD sends out the information, but no other routers are around to receive it.

     


RIP is designed so that a routing entry is only replaced if information is received about a shorter route; ties go to the incumbent, if you will. This means that once RD creates an entry for N1 with a cost of 3 going through RB, if it receives information that it can reach N1 at the same cost of 3 through RC, it will ignore it. Similarly, if it gets RC's info first, it will ignore the information from RB.

Naturally, this same propagation scheme will occur for all the other networks as well; I have just shown only how information about N1 moves from router to router. For example, Router A will eventually install an entry for N4 saying that it is reachable at a cost of 3 going through either RB or RC: this will be either {N4,RB,3} or {N4,RC,3}.

This propagation of network routing information occurs on a regular basis, and also when the structure of the network changes (due to either intentional changes in topography or failure of links or routers). When this happens the change information will move through the internetwork so that all routers are eventually updated. For example, suppose a connection were added from Router C to Network 1. If Router D previously had the entry {N1,RB,3}, it would eventually change this to {N1,RC,2}, since it could now reach N1 more quickly by going through Router C.


Previous Topic/Section
RIP Overview, History, Standards and Versions
Previous Page
Pages in Current Topic/Section
1
2
3
Next Page
RIP General Operation, Messaging and Timers
Next Topic/Section

If you find The TCP/IP Guide useful, please consider making a small Paypal donation to help the site, using one of the buttons below. You can also donate a custom amount using the far right button (not less than $1 please, or PayPal gets most/all of your money!) In lieu of a larger donation, you may wish to consider purchasing a download license of The TCP/IP Guide. Thanks for your support!
Donate $2
Donate $5
Donate $10
Donate $20
Donate $30
Donate: $



Home - Table Of Contents - Contact Us

The TCP/IP Guide (http://www.TCPIPGuide.com)
Version 3.0 - Version Date: September 20, 2005

© Copyright 2001-2005 Charles M. Kozierok. All Rights Reserved.
Not responsible for any loss resulting from the use of this site.