The Routing Information Protocol (RIP) is an Interior Gateway Protocol (IGP). This document discusses both RIP and Triggered RIP. OpenROUTE software supports RIP Version 1 (RIPv1), RIP Version 2 (RIPv2), Triggered RIPv1, and Triggered RIPv2. The document includes the following topics:
Interior Gateway Protocols
The Routing Information Protocol (RIP)
Triggered RIP
Displaying RIP Prompts
Configuring RIP
RIP Commands
Interior Gateway Protocols
Routers that use a common routing protocol form an Autonomous System (AS). This common routing protocol is called an Interior Gateway Protocol (IGP). IGPs dynamically detect network reachability and routing information within an AS and use this information to build the IP routing table. IGPs can also import external routing information into the AS.
Most router loads contain one IGP for building the IP routing table and that is RIP. However, many of the OpenROUTE software loads contain both RIP and OSPF. The Bellman-Ford or the distance-vector algorithm is the basis for RIP. Link-state technology or the Shortest-Path First (SPF) algorithm is the basis for the Open Shortest Path First (OSPF) protocol. Routers can run OSPF and RIP simultaneously.
The Routing Information Protocol (RIP)
RIP is a distance-vector protocol that allows routers to exchange information about destinations for computing routes throughout the network. You should use this routing protocol primarily in homogeneous networks of moderate size. In such networks, it may be to your advantage to run RIP rather than OSPF. (RIPv2 and Triggered RIP provide some of the advantages of OSPF without the complexity.)
Destinations may be either networks or a special destination used to convey a default route. RIP, like OSPF, does not alter IP packets and routes them based on destination address only.
Distance-vector algorithms make each router periodically broadcast its routing tables to all its neighbors. Then a router knowing its neighbors' tables can decide which destination neighbor to use for routing a packet.
Limitations
RIP has the following limitations. These limitations apply to both RIPv1 and RIPv2.
Limits an Autonomous System (AS) diameter to 15 hops.
Can result in sub-optimal routing because the hop count cannot adequately describe variations in a path's characteristics.
Finds new routes slowly when the network changes. This search consumes considerable bandwidth, and, in extreme cases, exhibits a slow convergence behavior referred to as a count to infinity.
Does not carry a subnet mask. Therefore, any subnet mask information can only be derived from the router's configuration.
Requires that all router interfaces running RIPv1 and configured with IP addresses in the same network class must be configured with the same subnet mask.
Requires that routes be aggregated to the network class boundary when routes are sent out over an interface of a different class.
Carries a subnet mask.
Supports password authentication security.
Specifies the next hop address.
Does not require that routes be aggregated on the network boundary.
Subnet Mask
With RIPv2, an interface's routing information contains a subnet mask. There is no guesswork about the subnet mask for a route.
With RIPv1, the interface's routing information does not contain a subnet mask; thus, the interface's subnet mask is not known to routers or systems outside the interface's own network. Such routers or systems assume that the subnet mask for the interface is the same as its network class mask. If the sending interface is in the same network as the interface receiving the RIP packet, however, it assumes that the subnet mask is the same as that configured for the destination interface.
With RIPv2, the RIPv1 restriction that router interfaces configured with addresses contained in the same network class have the same subnet mask no longer applies. Therefore, if you need variable subnet masks on the different router interfaces, you should configure RIPv2 to run on these interfaces.
With RIPv1, routing advertisements must be aggregated on the network class boundary when advertised outside the network. This is exactly what you need if your network class is completely contiguous, and there are no intervening networks that separate your network into non-contiguous segments.
However, if your network class is not contiguous, RIPv1 does not work since it has no subnet mask, and it must aggregate advertisements on the network class boundary. RIPv2 solves this problem and can be used to advertise the individual subnets that comprise each of the separate, non-contiguous segments of your network class.
Note: The ability to advertise subnets is something that OSPF could always do. You now have this ability by using RIPv2. OSPF is the superior routing protocol for large networks, but if you have a small or medium-sized network, RIPv2 may satisfy your needs if the ability to advertise subnets was the key criterion in your choice between RIP and OSPF.
Next Hop
RIPv2 can specify the next hop address to which the router sends packets destined for an advertised destination.
When Should I Choose RIPv1 Over RIPv2?
You can configure each interface on your router to use either RIPv1 or RIPv2 or both. Follow these guidelines in choosing a routing configuration:
Choose RIPv1 if you want routing advertisements to be aggregated on the network class boundary. Otherwise, choose RIPv2.
Configure all the router interfaces on the same physical IP network to run either RIPv1 or RIPv2, but not both.
Configure your router to run both RIPv1 and RIPv2 if there are routers on the same physical network that must use RIPv1 and others that must use RIPv2. Setting the Both option allows your router to interoperate with the RIPv1 routers and also the RIPv2 routers at the same time.
RIP Config> prompt, you use the enable/disable receiving and the enable/disable sending commands to configure RIP flags.
The set of routes sent out from a particular address is the union of the routes selected by setting any of the flags described in Table 1. At the RIP Config> prompt, you use the enable/disable sending commands to configure RIP send flags.
| Flag | If enabled, the interface . . . |
| Send All Routes | Sends all routes in RIP responses. |
| Send Default Routes | Advertises a default route in RIP responses if the router itself has a default gateway in operation. The router advertises the route to the default (authoritative) gateway as a route to destination 0.0.0.0. |
| Send Host Routes | Sends all host routes in RIP responses. (Usually only used with RIPv2.) |
| Send Net Routes | Sends all network-level routes in RIP responses. |
| Send Poisoned-Reverse Routes | Sends poisoned-reverse routes in RIP responses. (You can disable this flag if necessary.) |
| Send Static Routes | Advertises all directly connected networks and statically configured routes in RIP responses. |
| Send Subnet Routes | Sends appropriate subnet-level routes in RIP responses. |
The flags described in Table 2 control how the router incorporates information that RIP receives into its routing tables. At the RIP Config> prompt, you use the enable/disable receiving commands to configure RIP receive flags.
| Flag | If disabled, the interface ... |
|---|---|
| Receive RIP | Ignores RIP packets received on the specified interface. |
| Receive All Dynamic Routes | Accepts RIP updates for all routes specified by the add accept-rip route command. |
| Receive Dynamic Host Routes | Accepts RIP updates only for those hosts specified by the add accept-rip route command. |
| Receive Dynamic Net Routes | Accepts RIP updates only for those networks specified by the add accept-rip route command. |
| Receive Dynamic Subnet Routes | Accepts RIP updates only for those subnets specified by the add accept-rip route command. |
The flags described in Table 3 also control how the router incorporates information that RIP receives into its routing tables. Certain flag settings allow RIP routes to override static routing information, but only if the RIP metric is better than the static route's metric. At the RIP Config> prompt, you use the enable/disable override commands to configure RIP override flags.
| Flag | If enabled, RIP packets received on the interface ... |
| Override Default | May override the router's default gateway. |
| Override Static Routes | May override any of the router's statically configured routing information. |
Triggered RIP
The objective of Triggered RIP is to reduce IP routing traffic to zero traffic over a WAN connection as long as there are no changes to the routing database. It is a modification to RIP, which depends heavily on frequently broadcasting routing information to the router's neighbors. This periodic broadcast of routing information every few seconds can have the following results:
Consume a lot of bandwidth on point-to-point lines.
Interfere with normal data flow and run up the usage charge on demand circuits by always keeping the link up in order to exchange routing information.
OpenROUTE software allows you to configure either Triggered RIPv1 or Triggered RIPv2.
Triggered RIP runs only on a point-to-point WAN connection between two and only two routers. This means that it runs over a PPP interface or a Frame Relay interface that consists of a single Data Link Connection Identifier (DLCI).
Although Triggered RIP is similar to RIP, it is a completely different protocol. RIP and Triggered RIP are incompatible.
You must set the Triggered RIP send-option on routers at both ends of the link.
No Route Aging. The router treats all routes that it learns via Triggered RIP responses as permanent. That is, the routes do not age like routes that are learned across broadcast media and that get refreshed every 30 seconds.
Route Acknowledgment. Triggered RIP neighbors must acknowledge all routing updates. This implies that RIP cannot clear a deleted route from the routing table unless all of its neighbors have acknowledged the update.
However, if the router cannot make contact with a neighbor after a configured number of times, it clears its routes.
Retransmission. All Triggered RIP update responses are retransmitted until they are acknowledged.
Sub-optimal Routes. To take full advantage of Triggered RIP, for faster convergence, OpenROUTE software retains all alternate or sub-optimal routes that your router learns across Triggered RIP interfaces. Otherwise, a request for a full routing table update would have to be sent to all Triggered RIP neighbors each time a route is deleted from the database.
RIP config>), do the following:Config> prompt, enter protocol ip.
Config>protocol ip
Internet protocol user configuration
IP config>rip
IP config> prompt, enter rip.
Config>protocol ip
Internet protocol user configuration
IP config>rip
RIP config>
RIP>), do the following:Monitor> prompt, enter protocol ip.
Monitor>protocol ip
IP>
IP> prompt, enter rip.
IP>rip
RIP>
RIP Config>enable rip
By default, RIP advertises all network and subnet routes out all interfaces of the router that have assigned IP addresses or are using unnumbered IP. Once you enable RIP, you can configure what it listens to and what it advertises by setting the various RIP flags. Configure these flags for each interface. For information on the send, receive, and override flags, see Table 1, Table 2, and Table 3 respectively.
RIP config>set originate-rip-default
Always originate default route? [No]:
Originate default if EGP/BGP routes available? [No]: y
From AS number [0]?
To network number [0.0.0.0]?
Originate default if OSPF routes available? [No]:
Cost [1]?
RIPv2 next hop [0.0.0.0]?
You need to originate a RIP default route for the other routing protocols to which your network may be connected. This default route directs traffic bound for a non-RIP network to a boundary router that functions as a portal. Originating a single default route means that the boundary router does not have to distribute the other network's routing information to the other nodes on its network.
Answering Yes means a default route is always originated (that is, defaults to previous behavior). Answering Yes to the EGP/BGP question originates a default whenever there are EGP or BGP routes in the routing table. Answering Yes to if OSPF routes available causes the RIP default to be advertised when OSPF routes are in the routing table. When the router originates a RIP default, it uses the original default cost number.
RIP config>set send-option trigV1
Interface address [0.0.0.0]?11.2.84.42RIP config>set receive-option V1
Interface address [0.0.0.0]?11.2.84.42
You can verify the information you configured with the list protocol command.
RIP config>list protocol
Press Space twice after you type a command to display the available options for the command. Enter help for information about using the command line interface.
[C] means the command is available at the RIP config> prompt.
[M] means the command is available at the RIP> prompt.
Table 4 lists the RIP commands.
| Command | Function |
|---|---|
| Add [C] | Adds a RIP interface and the acceptance of a RIP route. |
| Clear [C] [M] |
At the RIP Config> prompt, clears all RIP information on all interfaces and resets all settings, including flags, to default settings. (If RIP is enabled, this command still clears RIP information, but RIP remains enabled.) |
| Delete [C] | Deletes a RIP interface and the acceptance of a RIP route. |
| Disable [C] | Disables RIP, a selected RIP interface, or the receiving or sending of RIP packets. |
| Dump [M] | Dumps routing tables. |
| Enable [C] | Enables RIP, a selected RIP interface, or the receiving or sending of RIP packets. |
| Interface [M] | Displays an interface summary. |
| List [C] | Lists RIP configuration information. |
| Neighbor [M] | Displays summary information on the router's neighbors. |
| Ping [M] | Sends requests to a designated address and waits for a response. |
| Route [M] | Routes a particular network address. |
| Set [C] | Sets RIP configuration parameters. |
| Statistics [M] | Displays RIP statistics on the router. |
| Traceroute [M] | Displays information on the routing destination path(s). |
Add [C]
Adds routes that accept RIP packets and interfaces that run RIP.
Note: This command has no effect if there are no disable receiving dynamic command settings
Example:add accept-rip-route
Network number [0.0.0.0]? 128.185.227.21
Interface address [0.0.0.0]? 128.185.227.21
RIP config>) and monitoring (RIP>) prompts.
Clear [C]
Deletes all configured interface records. RIP uses the default values for subsequent restarts.
Note: If you enabled RIP, it remains enabled after you use this command. All RIP parameters are set to default settings.
Syntax: clear Example:clear
All configured interface records will be deleted; RIP will use
the default values for subsequent restarts.
Are you sure you want to delete them (Yes or [No]):
clear
Specify nothing to clear global counters, or 'Interface ip_addr' to clear interface counters, or 'Neighbor ip_addr' to clear neighbor counters.
Example: delete accept-rip-route
Enter the address to be deleted [0.0.0.0]?128.185.227.10
Interface address [0.0.0.0]?128.185.227.16
Interface address [0.0.0.0]? 128.185.220.45
Example: disable override default
Set for which interface address [0.0.0.0]?128.185.223.67
Example: disable override static-routes
Set for which interface address [0.0.0.0]?128.185.223.67
Example: disable receiving rip
Set for which interface address [0.0.0.0]?128.185.223.67
disable receiving dynamic all
Set for which interface address [0.0.0.0]?128.185.220.64
rip
Turns off RIP.
sending
Prevents the router's selected interface from advertising all routes or selected routes.
disable sending default-routes
Set for which interface address [0.0.0.0]?128.185.223.6
Note: You can turn off the net-routes, subnet-routes, and static-routes flags individually. If you specify a route by any of the enabled flags, OpenROUTE software advertises the route.
This command is available at the RIP>
prompt for convenience. To display more information, enter this command at the
IP Config> prompt. See Using IP.
dump
Type Dest net Mask Cost Age Next hop(s)
Sbnt 50.0.0.0 FF000000 1 0 None
Dir* 50.10.1.0 FFFFFF00 1 0 Eth/0
Routing table size: 768 nets (64512 bytes), 2 nets known
An asterisk (*) after the route type indicates that the route has a static or directly connected backup. A percentage sign (%) after the route type indicates that the router always accepts RIP updates for this network or subnet.
A number in parentheses at the end of the column indicates the number of equal-cost routes to the destination.
Note: When you enable RIP, in order to be compatible with previous releases, OpenROUTE software enables RIP on all IP interfaces by default.
Example:enable interface
Interface address [0.0.0.0]?128.185.225.63
Example: enable override default
Set for which interface address [0.0.0.0]?128.185.223.67
Example: enable override static-routes
Set for which interface address [0.0.0.0]?128.185.223.67
Set for which interface address [0.0.0.0]?128.185.223.67
Syntax: enable receiving dynamic
enable receiving dynamic nets
Set for which interface address [0.0.0.0]?128.185.227.23
rip
Enables RIP processing on your router.
Note: Use the enable sending or disable sending commands to configure the RIP routing update sending behavior. Use the enable receiving or disable receiving and the enable override or disable override commands to configure the RIP routing update receiving behavior.
enable sending all-routes
Set for which interface address [0.0.0.0]?128.185.66.31
Interface [M]
Displays a summary of the running state of all configured RIP interfaces. Also, displays the configured values and the neighbors that it recognizes on its network, if you specify a particular interface in the command.
interface 50.10.1.63
IP-Address Intf State BadPkts BadRtes TrigUpdts Nbrs (V1)
50.10.1.63 Eth/0 On 0 39663 13513 0 (0)
If you enter a specific interface address with the interface command, the software displays additional information on the designated interface.
IP-Address Intf State BadPkts BadRtes TrigUpdts Nbrs (V1)
50.10.1.6 Eth/0 On 0 39663 13513 0 (0)Source Address: 50.10.1.65
Authentication Type: None
Default cost: 0
Send option: V1&2
Receive option: V1&2
Per-interface address flags: Send net and subnet routes
Receive No Dynamic host routes
Neighbors: None
RIP: enabled
Intf IP-address Source-address State AuType DefCost Send Recv
0 50.10.1.6 50.10.1.6 On None 0 V1 V1
RIP default origination: disabled
Per-interface address flags:
intf 0 50.10.1.6 Send net, subnet and host routes
Accept RIP updates always for:
128.185.227.22 128.185.227.21
Note:
When you run the list all and list protocol commands, the only
Per-interface address flags displayed are the enabled send flags and the disabled receive flags.
RIP: enabled
Intf IP-address Source-address State AuType DefCost Send Recv
0 50.10.1.65 50.10.1.65 On None 0 V1 V1
RIP default origination: disabled
Per-interface address flags:
intf 0 50.10.1.65 Send net, subnet and host routes
rip-routes-accept
Displays the set of routes that RIP always accepts.
Example: list rip-routes-accept
Accept RIP updates always for:
128.185.227.22 128.185.227.21
neighbor
Neighbor-Addr Phys Vers Age BadPkts BadRtes RxSeq
128.185.223.1 PPP/0 V2 20 0 0 n/a
128.185.112.2 PPP/1 V2 10 0 0 n/a
Ping [M]
Causes your router to send Internet Control Message Protocol (ICMP) Echo Requests to a given destination once per second and then watch for a response. You can use the ping command to isolate trouble in an internetwork environment.
The ping process continues incrementing the ICMP sequence number with each additional packet. OpenROUTE software reports matching ICMP Echo responses received with their sequence number and the round-trip time. The process stops when you type a character. At that time, OpenROUTE displays a summary of packet loss, round-trip time, and the number of ICMP unreachable destinations. The round trip usually takes about 20 milliseconds (depending on the router platform).
When a destination has a multicast address, the software may display multiple responses for each packet sent, one for each member of the multicast group. Each response contains the source address of the responding system.
Note: The size of the ping (number of data bytes in the ICMP message, excluding the ICMP header) is 56 bytes, and the TTL is 60 seconds.
This command is available at theRIP> prompt
for convenience. To display more information, enter this command at the IP
Config> prompt. See Using IP.
Syntax: ping interface-address
Example:ping 128.185.142.11
PING 128.185.142.11: 56 data bytes
64 bytes from 128.185.142.11: icmp_seq=0. time=0. ms
64 bytes from 128.185.142.11: icmp_seq=1. time=0. ms
64 bytes from 128.185.142.11: icmp_seq=2. time=0. ms
64 bytes from 128.185.142.11: icmp_seq=3. time=0. ms
64 bytes from 128.185.142.11: icmp_seq=4. time=0. ms
64 bytes from 128.185.142.11: icmp_seq=5. time=0. ms
----128.185.142.11 PING Statistics----
6 packets transmitted, 6 packets received, 0% packet loss
round-trip (ms) min/avg/max = 0/0/0
This command is available at the RIP Config>
prompt for convenience. To display more information, enter this command at the
IP Config> prompt. See Using IP.
Syntax: route ip_destination_address
Example:route 50.10.1.6
Destination: 50.10.1.0
Mask: 255.255.255.0
Route type: Dir
Distance: 1
Age: 0
Next hop(s): 50.10.1.65 (Eth/0)
Tag: 0x00000000
Note: You should configure all routers on the same IP network with the same type of authentication.
Syntax: set authenticationset authentication none
Interface address [0.0.0.0]?
set authentication simple-password
Interface address [0.0.0.0]? 50.10.1.65
Authentication key? john
Enter Auth key again? john
|
None
| No password checks. This is the default. |
|
Simple-password
| Use a cleartext password. Such a password is in alphanumeric or character mode. |
default-metric
Sets the default metric to be used for the default route on this interface. The metric range is 1-15 hops, and 0 (zero) is the default value.
If you set the default metric to 0, OpenROUTE software uses the global default metric that you specified by the set-originate-rip-default command.
When you first define an interface, OpenROUTE software sets the default metric value for the interface to 0. If you specify the default metric, however, the defined metric takes precedence over the one you configured with the set originate-rip-default command. This applies for both RIPv1 and RIPv2.
Interface address [0.0.0.0]? 50.10.1.65
Default metric (1-15), or 0 to use the global default [0]? 1
The range is 1-255. The default is 5.
Interface address [0.0.0.0]? 50.10.1.65
Maximum number of retries (1-255) [36]? 5
This default route directs traffic bound for a non-RIP network to a boundary router that functions as a portal. Originating a single default route means that the boundary router does not have to distribute the other network's routing information to the other nodes on its network.
When you enter this command, the software prompts you to originate a RIP default route for the other routing protocols to which your network may be connected.
Note: The next hop field only exists in the RIPv2 packet format, not in RIPv1 packet format.
The default cost is placed into the metric field of the RIP default route, v1 or v2, unless you have overriden it by setting a specific default cost for the interface by the set-default-metric command.
Example: set originate-rip-default
Example:Always originate default route? [No]:
Originate default if EGP/BGP routes available? [No]:
Originate default if OSPF routes available? [No]:
set originate-rip-default
Example:Always originate default route? [No]: y
Cost [3]?
RIPv2 next hop [1.2.3.4]?
set originate-rip-default
Note: The actual displays in the examples depend on your router's current configuration and your responses to the queries.Always originate default route? [Yes]: n
Originate default if EGP/BGP routes available? [No]: y
From AS number [0]?
To network number [0.0.0.0]?
Originate default if OSPF routes available? [No]: y
Cost [3]?
RIPv2 next hop [1.2.3.4]?
The range is 1-3600 seconds. The default is 60 seconds.
Interface address [0.0.0.0]? 128.181.97.16
Poll Timer [30]?
set receive-option both
All interfaces (Yes or [No]):
Interface address [0.0.0.0]? 126.181.26.2
|
None
| Receive no RIP packets at all. |
|
Both
| Receive both RIPv1 and RIPv2 packets. |
|
V1
| Receive only RIPv1 packets. |
|
V2
| Receive only RIP v2 packets. This is the default. |
reply-timer
For Triggered RIP, sets the number of seconds to wait for a routing response or acknowledgment from the neighbor on a given interface before retransmitting the routing request or response.
The range is 1-255 seconds. The default is 5 seconds.
Interface address [0.0.0.0]? 50.10.1.6
Reply Timer [5]?
set send-option both
All interfaces (Yes or [No]):
Interface address [0.0.0.0]? 128.185.226.25
Note: Triggered RIP only runs on point-to-point interfaces. OpenROUTE software interprets Triggered RIPv1 and Triggered RIPv2 as RIPv1 and RIPv2 respectively on other interface types.
Note: The source address must be either one of the router's interface addresses or the router's internal IP address.
If you configure this field, OpenROUTE sets the RIPv1 packet source to the specified source address.
Interface address [0.0.0.0]? 50.10.1.6
Source address [0.0.0.0]? 128.180.22.13
statistics
Originate default route: No (0, 0.0.0.0)
RIP interfaces: 1
Memory allocation failures: 0
I/O buffer allocation failures: 0
Responses sent to neighbors queries: 12
Changes made to the routing database: 10591
Traceroute [M]
Displays the entire path to a destination, hop by hop. For each successive hop, the traceroute command sends out three probes and displays the IP address of the responding system, together with the round-trip time associated with the response. If a particular probe receives no response, the software displays an asterisk. Each line in the display relates to the set of three probes, with the left-most number indicating the distance (in router hops) from the router sending the command.
The destination is reached.
An ICMP Destination Unreachable is received.
The path length reaches 32 router hops.
This command is available at the RIP>
prompt for convenience. For more information, enter this command at the IP>
prompt. See Using IP.
Syntax: traceroute interface address
Example:traceroute 128.185.124.110
TRACEROUTE 128.185.124.110: 56 data bytes
1 128.185.142.7 16 ms 0 ms 0 ms
2 128.185.123.22 16 ms 0 ms 16 ms
3 * * *
4 * * *
5 128.185.124.110 16 ms ! 0 ms ! 0 ms !