RIP Default Route

Lesson Contents

Most routing protocols allow you to advertise a default route, RIP is no exception. This can be useful if you have a single exit point in your network. Let me give you an example:

Rip Default Route Lab Topology

Above we have a customer network on the right side, using R1, R2, and R3. On the left side, there’s the ISP. The loopback on the ISP1 router is supposed to be some network on the Internet.

To reach the Internet, R1, R2, and R3 should have a default route. There are two ways how we can configure this:

  • We could configure a static default route on R1, R2 and R3.
  • We could configure a static default route on R1 and advertise it in RIP to R2 and R3.

I’ll show you how to configure option 2.

Configuration





Let’s start with a basic RIP configuration for R1, R2 and R3 so that all internal links are advertised:

R1(config)#router rip
R1(config-router)#version 2
R1(config-router)#no auto-summary 
R1(config-router)#network 192.168.12.0
R1(config-router)#network 192.168.13.0
R2(config)#router rip       
R2(config-router)#version 2
R2(config-router)#no auto-summary 
R2(config-router)#network 192.168.12.0
R3(config)#router rip
R3(config-router)#version 2
R3(config-router)#no auto-summary 
R3(config-router)#network 192.168.13.0

Let’s configure a static default route on R1 to reach the networks behind the ISP1 router:

R1(config)#ip route 0.0.0.0 0.0.0.0 192.168.14.4

Let’s see if it works:

R1#ping 4.4.4.4
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 4.4.4.4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 2/2/4 ms

No problems there. Time to advertise it in RIP:

R1(config)#router rip
R1(config-router)#default-information originate 

The command above will tell RIP to advertise the static default route.

Let’s see what we have on R2 and R3:

R2#show ip route rip 

Gateway of last resort is 192.168.12.1 to network 0.0.0.0

R*    0.0.0.0/0 [120/1] via 192.168.12.1, 00:00:26, GigabitEthernet0/1
R     192.168.13.0/24 [120/1] via 192.168.12.1, 00:00:26, GigabitEthernet0/1
R3#show ip route rip  

Gateway of last resort is 192.168.13.1 to network 0.0.0.0

R*    0.0.0.0/0 [120/1] via 192.168.13.1, 00:00:18, GigabitEthernet0/1
R     192.168.12.0/24 [120/1] via 192.168.13.1, 00:00:18, GigabitEthernet0/1

Both routers have a default route, learned from R1. Let’s test these:

R2#ping 4.4.4.4
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 4.4.4.4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/3/4 ms
R3#ping 4.4.4.4
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 4.4.4.4, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 3/4/6 ms

Our default route learned through RIP is working.

The pings from R2 and R3 will only work if you have a route on the ISP1 router for the 192.168.12.0/24 and 192.168.13.0/24 networks. I achieved this with a static route on the ISP1 router.

Configurations

Want to take a look for yourself? Here you will find the final configuration of each device.

ISP1

hostname ISP1
!
ip cef
!
interface Loopback0
 ip address 4.4.4.4 255.255.255.0
!
interface GigabitEthernet0/1
 ip address 192.168.14.4 255.255.255.0
!
ip route 192.168.0.0 255.255.0.0 192.168.14.1
!
end

R1

hostname R1
!
ip cef
!
interface GigabitEthernet0/1
 ip address 192.168.14.1 255.255.255.0
!
interface GigabitEthernet0/2
 ip address 192.168.12.1 255.255.255.0
!
interface GigabitEthernet0/3
 ip address 192.168.13.1 255.255.255.0
!
router rip
 network 192.168.12.0
 network 192.168.13.0
 default-information originate
 no auto-summary
!
ip route 0.0.0.0 0.0.0.0 192.168.14.4
!
end

R2

hostname R2
!
ip cef
!
interface GigabitEthernet0/1
 ip address 192.168.12.2 255.255.255.0
!
router rip
 network 192.168.12.0
 no auto-summary
!
end

R3

hostname R3
!
ip cef
!
interface GigabitEthernet0/1
 ip address 192.168.13.3 255.255.255.0
!
router rip
 network 192.168.13.0
 no auto-summary
!
end

Conclusion

You have learned how you can use the default-information originate command to advertise a default route in RIP. Make sure you have a default route in your own routing table, otherwise this command will not work.

Tags:


Forum Replies

  1. Hi Rene,

    Looking at R1’s configuration, you have not involved/advertised network towards ISP in RIP process. So how it will send RIP updates on ISP connecting interface?

  2. Hello Swapnil

    RIP is an Interior Gateway Routing Protocol (IGRP) which means that it functions within an organization’s or an enterprise network. RIP and other IGRPs (such as OSPF or EIGRP) are not regularly used by ISPs and their internal networks as they usually use BGP.

    So R1 will not share its routing information with the ISP router nor with the ISP router share its information with R1. (If sharing of routes between ISP and R1 routers was enabled, it would most likely use BGP).

    However, in order for R1 to route correctly to 4.4.4.4 (and to any other desti

    ... Continue reading in our forum

  3. Hi,

    In the lesson, it is stated that R1 sens RIP updates toward ISP also, but under ‘router rip’ there is no 192.168.14.0 so it shouldn’t send? Could you check again?

    R1(config)#router rip
    R1(config-router)#version 2
    R1(config-router)#no auto-summary 
    R1(config-router)#network 192.168.12.0
    R1(config-router)#network 192.168.13.0
    

    regards,

  4. Hello Murat

    When a router is configured to fun the RIP routing protocol, it sends out RIP updates from ALL of its interfaces, regardless of which networks are being advertised. This means that RIP updates will be sent to the ISP, but will be ignored. For this reason, it is a good idea to make such interfaces passive, to eliminate needless RIP updates.

    Keep in mind that the network command simply states which networks will be advertised. It does not affect which interfaces will send RIP updates. It is the passive command that disables the (default) behaviour

    ... Continue reading in our forum

  5. Hello,

    Just a few comments:

    On the topology picture ISP1 should have .4 on Gi0/1.

    Also the behavior for RIP is a bit different than OSPF related to default-information originate.
    Default route is injected in RIP updates although there is no default route configured on DUT that does default-information originate. Not sure yet if this is a bug or wanted behavior…

    https://learningnetwork.cisco.com/thread/124779

    So the note “The default-information originate command only works if you have a default route in your own routing table.” is not mandatory.

    Many thanks,
    Stefanita

7 more replies! Ask a question or join the discussion by visiting our Community Forum