RIP Demand Circuits
RIP Demand Circuits Overview
RIP periodically sends routing information (RIP packets) to neighboring devices. These periodic broadcasts can consume bandwidth resources and interfere with network traffic by preventing WAN circuits from being closed. Demand circuits for RIP is defined in RFC 2091 and overcomes these issues by exchanging incremental updates on demand.
A demand circuit is a point-to-point connection between two neighboring interfaces configured for RIP. Demand circuits preserve bandwidth by establishing a link when data needs to be transferred, and terminating the link when the data transfer is complete. Demand circuits increase the efficiency of RIP on the configured interfaces by offering minimal network overhead in terms of messages passed between the demand circuit end points, conserving resources, and reducing costs.
By configuring RIP demand circuits, a specific event triggers the device to send an update, thereby eliminating the periodic transmission of RIP packets over the neighboring interface. To save overhead, the device sends RIP information only when changes occur in the routing database, such as:
The device is first powered on
The device receives a request for route update information
A change occurs in the network
The demand circuit goes down or comes up
The device sends update requests, update responses, and acknowledgments. In addition, the device retransmits updates and requests until valid acknowledgments are received. The device dynamically learns RIP neighbors. If the neighboring interface goes down, RIP flushes routes learned from the neighbor’s IP address.
Routes learned from demand circuits do not age like other RIP entries because demand circuits are in a permanent state. Routes in a permanent state are only removed under the following conditions:
A formerly reachable route changes to unreachable in an incoming response
The demand circuit is down due to an excessive number of unacknowledged retransmissions
You can also set the RIP hold-down timer and the RIP demand circuit retransmission timer to regulate performance. The demand circuit uses these timers to determine if there is a change that requires update messages to be sent. There is also a database timer that runs only when RIP flushes learned routes from the routing table.
This topic includes the following sections:
RIP Demand Circuit Packets
When you configure an interface for RIP demand circuits, the supported command field packet types are different than those for RIP version 1 and RIP version 2. RIP packets for RIP demand circuits contain three additional packet types and an extended 4-byte update header. Both RIP version 1 and RIP version 2 support the three packet types and the extended 4-byte header. Table 1 describes the three packet types.
Packet Type |
Description |
---|---|
Update Request |
Update request messages seek information for the device’s routing table. This message is sent when the device is first powered on or when a down demand circuit comes up. The device sends this message every 5 seconds (by default) until an update response message is received. |
Update Response |
Update response messages are sent in response to an update request message, which occurs when the device is first powered on or when a down demand circuit comes up. Each update response message contains a sequence number that the neighbor uses to acknowledge the update request. |
Update Acknowledge |
Update acknowledge messages are sent in response to every update response message received by the neighbor. |
These packets are only valid on interfaces configured for RIP demand circuits. If a demand circuit receives a RIP packet that does not contain these packet types, it silently discards the packet and logs an error message similar to the following:
Ignoring RIP packet with invalid version 0 from neighbor 10.0.0.0 and source 10.0.0.1
Timers Used by RIP Demand Circuits
RIP demand circuits use the RIP hold-down timer and the RIP demand circuit retransmission timer to regulate performance and to determine if there is a change in the network that requires the device to send update messages. The hold-down timer is a global RIP timer that affects the entire RIP configuration; whatever range you configure for RIP applies to RIP demand circuits. The retransmission timer affects only RIP demand circuits. In addition, there is a database timer that runs only when RIP flushes learned routes from the routing table.
Hold-down timer (global RIP timer)—Use the hold-down timer to configure the number of seconds that RIP waits before updating the routing table. The value of the hold-down timer affects the entire RIP configuration, not just the demand circuit interfaces. The hold-down timer starts when a route timeout limit is met, when a formerly reachable route is unreachable, or when a demand circuit interface is down. When the hold-down timer is running, routes are advertised as unreachable on other interfaces. When the hold-down timer expires, the route is removed from the routing table if all destinations are aware that the route is unreachable or the remaining destinations are down. By default, RIP waits 120 seconds between routing table updates. The range is from 10 to 180 seconds.
Retransmission timer (RIP demand circuit timer)—RIP demand circuits send update messages every 5 seconds to an unresponsive peer. Use the retransmission timer to limit the number of times a demand circuit resends update messages to an unresponsive peer. If the configured retransmission threshold is reached, routes from the next hop router are marked as unreachable and the hold-down timer starts. The value of the retransmission timer affects only the demand circuit interfaces. To determine the number of times to resend the update message, use the following calculation:
5 seconds * number of retransmissions = retransmission seconds
The retransmission range is from 5 through 180 seconds, which corresponds to sending an update message a minimum of 1 time (5 seconds) and a maximum of 36 times (180 seconds).
Database timer (global timeout timer)—Routes learned from demand circuits do not age like other RIP entries because demand circuits are in a permanent state. On a RIP demand circuit, the database timer starts upon receipt of the update response message with the flush flag sent from a RIP demand circuit peer. When the neighbor receives this message, all routes from that peer are flushed, and the database timer starts and runs for the configured route timeout interval. When the database timer is running, routes are still advertised as reachable on other interfaces. When the database timer expires, the device advertises all routes from its peer as unreachable.
See Also
Example: Configuring RIP Demand Circuits
This example describes how to configure an interface as a RIP demand circuit.
Requirements
Before you begin, configure the device interfaces. See the Junos OS Network Interfaces Library for Routing Devices or the Junos OS Interfaces Configuration Guide for Security Devices.
Overview
A demand circuit is a point-to-point connection between two neighboring interfaces configured for RIP. Demand circuits increase the efficiency of RIP on the configured interfaces by eliminating the periodic transmission of RIP packets. Demand circuits preserve bandwidth by establishing a link when data needs to be transferred, and terminating the link when the data transfer is complete. In this example, two devices are connected using SONET/SDH interfaces.
When you configure RIP demand circuits, any silent removal of the RIP configuration goes unnoticed by the RIP peer and leads to stale entries in the routing table. To clear the stale entries, deactivate and reactivate RIP on the neighboring devices.
In this example, you configure interface so-0/1/0 with the following settings:
demand-circuit—Configures the interface as a demand circuit. To complete the demand circuit, you must configure both ends of the pair as demand circuits.
max-retrans-time—RIP demand circuits send update messages every 5 seconds to an unresponsive peer. Use the retransmission timer to limit the number of times a demand circuit resends update messages to an unresponsive peer. If the configured retransmission threshold is reached, routes from the next-hop router are marked as unreachable, and the hold-down timer starts. The value of the retransmission timer affects only the demand circuit interfaces. To determine the number of times to resend the update message, use the following calculation:
5 seconds x retransmissions = retransmission seconds
For example, if you want the demand circuit to send only two update messages to an unresponsive peer, the calculation is: 5 x 2 = 10. When you configure the retransmission timer, you enter 10 seconds.
The retransmission range is from 5 through 180 seconds, which corresponds to sending an update message a minimum of 1 time (5 seconds) and a maximum of 36 times (180 seconds).
Configuration
In the following example, you configure a neighboring interface to be a RIP demand circuit and save the configuration.
Procedure
CLI Quick Configuration
To quickly configure this example, copy the
following commands, paste them into a text file, remove any line breaks,
change any details necessary to match your network configuration,
and then copy and paste the commands in the CLI at the [edit]
hierarchy level.
set interfaces so-0/1/0 unit 0 family inet address 192.0.2.0/24 set protocols rip group group1 neighbor so-0/1/0 demand-circuit set protocols rip group group1 neighbor so-0/1/0 max-retrans-time 10
Step-by-Step Procedure
The following example requires that you navigate various levels in the configuration hierarchy. For information about navigating the CLI, see Using the CLI Editor in Configuration Mode in the CLI User Guide.
To configure a RIP demand circuit on one neighboring interface:
Configure the interface.
[edit interfaces] user@host# set so-0/1/0 unit 0 family inet address 192.0.2.0/24
Configure the neighbor as a demand circuit.
[edit protocols rip] user@host# set group group1 neighbor so-0/1/0 demand-circuit
Configure the demand circuit retransmission timer.
[edit protocols rip] user@host# set group group1 neighbor so-0/1/0 max-retrans-time 10
If you are done configuring the device, commit the configuration.
[edit] user@host# commit
Note:Repeat this entire configuration on the other neighboring interface.
Results
Confirm your configuration by entering the show
interfaces
and show protocols
commands. If the output
does not display the intended configuration, repeat the instructions
in this example to correct the configuration.
user@host# show interfaces so-0/1/0 { unit 0 { family inet { address 192.0.2.0/24; } } }
user@host# show protocols rip { group group1 { neighbor so-0/1/0 { demand-circuit; max-retrans-time 10; } } }
Verification
Confirm that the configuration is working properly.
Verifying a Demand Circuit Configuration
Purpose
Verify that the demand circuit configuration is working.
Action
To verify that the demand circuit configuration is in effect, use the show rip neighbor operational mode command.
user@host> show rip neighbor Source Destination Send Receive In Neighbor State Address Address Mode Mode Met -------- ----- ------- ----------- ---- ------- --- so-0/1/0.0(DC) Up 10.10.10.2 224.0.0.9 mcast both 1
When you configure demand circuits, the show rip neighbor
command displays a DC flag next to the neighboring interface configured
for demand circuits.
If you configure demand circuits at the [edit protocols
rip group group-name neighbor neighbor-name]
hierarchy level, the output shows only the neighboring interface
that you specifically configured as a demand circuit. If you configure
demand circuits at the [edit protocols rip group group-name]
hierarchy level, all of the interfaces in the group are configured
as demand circuits. Therefore, the output shows all of the interfaces
in that group as demand circuits.