RIP Protocol

RIP Protocol in the Lab

This lab demonstrates how to use the RIP protocol to route traffic across some common network devices like routers and multilayer switches utilising VLAN settings.

Topology: consists of two routers, one multilayer switch, and three layer 2 switches.

The multilayer switch L3 is connected to router R-2 (on the right) and the Layer 2 switch (L2) on the left. The layer 2 switch, L2 (left side), is set up with 2 off VLAN nodes in relation to both access ports, Fa0/1 for VLAN 10 and Fa0/2 for VLAN 20.

Router 2 (R-2) on its port G0/1 is connected to the Layer 2 switch (Switch1) with subnetwork 192.168.10.0/24. Lastly, router 1 (R-1) is directly connected to router 2 (R-2) on the G0/0 port and to the layer 2 switch on the subnetwork 192.168.20.0/24, on port G0/1.

A multilayer switch L3, router R-2, and R-1 are set up with the RIP protocol to process the packet handling inter-VLAN in the network. 

Multilayer Switch L3 configuration

In this example, the multilayer switch (L3) is set up to the following configuration of virtual interfaces of VLAN10 and 20, which relates to the left part of the topology. It will help to route the packets between the VLANs. 

The link between the multilayer switch (L3) and the layer 2 switch (L2) is set up in trunk mode. Port Fa0/3 is in auto mode, directly connected to a PC with IP address 172.16.99.101.

Port Fa0/1 (L3 Switch) is set up to “no switchport” mode to enable routing with connected routers. The option of the route table of the multilayer switch (L3) is enabled using a command: “ip routing." 

In that configuration, the port Fa0/1 (L3 switch) is set with IP address 192.10.20.254/24.

Port Fa0/3 is set with the IP address 172.16.99.254/24, with a disabled switchport option. So this port is fully routable as well.

On the L3 switch, RIP routing is activated as shown on the script below:

router rip

version 2

no auto-summary

network 172.16.0.0

network 192.10.20.0

network 192.10.10.0

network 192.168.10.0

network 192.168.20.0

network 192.168.99.0

Router 2 (R2) configuration

On router 2 (R-2), three off ports are operational overall, configured as follows:

interface g0/0: 192.10.10.1/24

RIP protocol is initiated in router 2 with the same configuration as was done on switch L3.

router rip

version 2

no auto-summary

network 172.16.0.0

network 192.10.20.0

network 192.10.10.0

network 192.168.10.0

network 192.168.20.0

network 192.168.99.0

Router 1 (R1) configuration

On router 1, there are 2 active ports with the following IP addresses:

interface g0/0: 192.10.10.2/

interface g0/1: 192.168.20.254/24

Also, on router 1, the RIP protocol is installed in the same configuration as for the rest of the packet-routable devices.

router rip

version 2

no auto-summary

network 172.16.0.0

network 192.10.20.0

network 192.10.10.0

network 192.168.10.0

network 192.168.20.0

network 192.168.99.0

VLANs on switch L3

For the VLAN propagation, the VTP protocol was used in the following setup:

vtp domain ccna

vtp mode server

vtp password ccna

As you can see, there are 4 active VLANs that are sharing between switches on the trunk connection.

Switch#show vlan brief


VLAN Name                             Status    Ports

---- -------------------------------- --------- -------------------------------

1    default                          active    Fa0/4, Fa0/5, Fa0/6, Fa0/7

                                                Fa0/8, Fa0/9, Fa0/10, Fa0/11

                                                Fa0/12, Fa0/13, Fa0/14, Fa0/15

                                                Fa0/16, Fa0/17, Fa0/18, Fa0/19

                                                Fa0/20, Fa0/21, Fa0/22, Fa0/23

                                                Fa0/24, Gig0/1, Gig0/2

10   Sale                             active    Fa0/1

20   Engineering                      active    Fa0/2

30   Marketing                        active    

99   Service                          active    

1002 fddi-default                     active    

1003 token-ring-default               active    

1004 fddinet-default                  active    

1005 trnet-default                    active 

As mentioned above, the RIP configuration has been done in the CLI command line, and all settings can be confirmed by the command "show ip protocols.”.

However, the picture below shows the same settings in a graphical way. In this lab, to see the RIP setting, I use a graphical window from PT to simplify the lab.

Switch 3: RIP protocol configuration shown in PT.

The command below, “show ip interface brief," shows physical and virtual port configuration. Note that I used the shortcut “int” in the world of interfaces.

Switch#show ip int brief

Interface              IP-Address      OK? Method Status                Protocol 

FastEthernet0/1        192.10.20.254   YES manual up                    up 

FastEthernet0/2        unassigned      YES unset  up                    up 

FastEthernet0/3        unassigned      YES unset  up                    up 

FastEthernet0/4        unassigned      YES unset  down                  down 

FastEthernet0/5        unassigned      YES unset  down                  down 

FastEthernet0/6        unassigned      YES unset  down                  down 

FastEthernet0/7        unassigned      YES unset  down                  down 

FastEthernet0/8        unassigned      YES unset  down                  down 

FastEthernet0/9        unassigned      YES unset  down                  down 

FastEthernet0/10       unassigned      YES unset  down                  down 

FastEthernet0/11       unassigned      YES unset  down                  down 

FastEthernet0/12       unassigned      YES unset  down                  down 

FastEthernet0/13       unassigned      YES unset  down                  down 

FastEthernet0/14       unassigned      YES unset  down                  down 

FastEthernet0/15       unassigned      YES unset  down                  down 

FastEthernet0/16       unassigned      YES unset  down                  down 

FastEthernet0/17       unassigned      YES unset  down                  down 

FastEthernet0/18       unassigned      YES unset  down                  down 

FastEthernet0/19       unassigned      YES unset  down                  down 

FastEthernet0/20       unassigned      YES unset  down                  down 

FastEthernet0/21       unassigned      YES unset  down                  down 

FastEthernet0/22       unassigned      YES unset  down                  down 

FastEthernet0/23       unassigned      YES unset  down                  down 

FastEthernet0/24       unassigned      YES unset  down                  down 

GigabitEthernet0/1     unassigned      YES unset  down                  down 

GigabitEthernet0/2     unassigned      YES unset  down                  down 

Vlan1                  172.16.99.254   YES manual up                    up 

Vlan10                 172.16.10.254   YES manual up                    up 

Vlan20                 172.16.20.254   YES manual up                    up

Routes shown on the switch L3 with the connection to subnets.

Switch#show ip route

Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route


Gateway of last resort is not set


     172.16.0.0/24 is subnetted, 3 subnets

C       172.16.10.0 is directly connected, Vlan10

C       172.16.20.0 is directly connected, Vlan20

C       172.16.99.0 is directly connected, Vlan1

R    192.10.10.0/24 [120/1] via 192.10.20.1, 00:00:08, FastEthernet0/1

C    192.10.20.0/24 is directly connected, FastEthernet0/1

R    192.168.10.0/24 [120/1] via 192.10.20.1, 00:00:08, FastEthernet0/1

R    192.168.20.0/24 [120/2] via 192.10.20.1, 00:00:08, FastEthernet0/1


L3 switch with active command to present RIP protocol.

Switch#show ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 6 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is not set

Incoming update filter list for all interfaces is not set

Redistributing: rip

Default version control: send version 2, receive 2

  Interface             Send  Recv  Triggered RIP  Key-chain

  Vlan1                 2 2 

  FastEthernet0/1       22

  Vlan10                22

  Vlan20                22

Automatic network summarization is not in effect

Maximum path: 4

Routing for Networks:

172.16.0.0

192.10.10.0

192.10.20.0

192.168.10.0

192.168.20.0

Passive Interface(s):

Routing Information Sources:

Gateway         Distance      Last Update

192.10.20.1          120      00:00:13

Distance: (default is 120)

Router 2 setup

The PT configuration mode window for router 2 shows active network addresses to transfer packets using the RIP protocol.Again we can make the setup from the command line or directly in the PT software.I made the network routing setup directly in the PT software for router 2.

Below has been shown the interface configuration with IP addresses for Route 2.

R-2#show ip int brief

Interface              IP-Address      OK? Method Status                Protocol 

GigabitEthernet0/0     192.10.10.1     YES manual up                    up 

GigabitEthernet0/1     192.168.10.254  YES manual up                    up 

GigabitEthernet0/2     192.10.20.1     YES manual up                    up 

Vlan1                  unassigned      YES unset  administratively down down

As we mentioned previously, the multilayer switch L3 is set to trunk mode on the port Fa0/2. Therefore, the summary of trunk connection you can see in the script below. The native LAN has not been changed, but it is strongly recommended to change it in production due to security issues.

Switch#show int trunk

Port        Mode         Encapsulation  Status        Native vlan

Fa0/2       on           802.1q         trunking      1


Port        Vlans allowed on trunk

Fa0/2       1-1005


Port        Vlans allowed and active in management domain

Fa0/2       1,10,20,30,99


Port        Vlans in spanning tree forwarding state and not pruned

Fa0/2       1,10,20,30,99

Router 2 with shown routes to the local subnets.

R-2#show ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route


Gateway of last resort is not set


     172.16.0.0/24 is subnetted, 3 subnets

R       172.16.10.0/24 [120/1] via 192.10.20.254, 00:00:18, GigabitEthernet0/2

R       172.16.20.0/24 [120/1] via 192.10.20.254, 00:00:18, GigabitEthernet0/2

R       172.16.99.0/24 [120/1] via 192.10.20.254, 00:00:18, GigabitEthernet0/2

     192.10.10.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.10.10.0/24 is directly connected, GigabitEthernet0/0

L       192.10.10.1/32 is directly connected, GigabitEthernet0/0

     192.10.20.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.10.20.0/24 is directly connected, GigabitEthernet0/2

L       192.10.20.1/32 is directly connected, GigabitEthernet0/2

     192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.168.10.0/24 is directly connected, GigabitEthernet0/1

L       192.168.10.254/32 is directly connected, GigabitEthernet0/1

R    192.168.20.0/24 [120/1] via 192.10.10.2, 00:00:11, GigabitEthernet0/0

Router 2 RIP protocol was checked using the command “show ip protocol”.

R-2#show ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 24 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is not set

Incoming update filter list for all interfaces is not set

Redistributing: rip

Default version control: send version 2, receive 2

  Interface             Send  Recv  Triggered RIP  Key-chain

  GigabitEthernet0/0    22

  GigabitEthernet0/1    22

  GigabitEthernet0/2    22

Automatic network summarization is not in effect

Maximum path: 4

Routing for Networks:

172.16.0.0

192.10.10.0

192.10.20.0

192.168.10.0

192.168.20.0

Passive Interface(s):

Routing Information Sources:

Gateway         Distance      Last Update

192.10.20.254        120      00:00:11

192.10.10.2          120      00:00:03

Distance: (default is 120)

The following several scripts show the configuration for router 1. Again, it includes RIP protocol, port configuration, and route table information.

Interface settings on the router 1. 

R-1#show ip int brief

Interface              IP-Address      OK? Method Status                Protocol 

GigabitEthernet0/0     192.10.10.2     YES manual up                    up 

GigabitEthernet0/1     192.168.20.254  YES manual up                    up 

GigabitEthernet0/2     unassigned      YES unset  administratively down down 

Vlan1                  unassigned      YES unset  administratively down down

Route table extracted from route 1.

R-1#show ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

       i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route


Gateway of last resort is not set


     172.16.0.0/24 is subnetted, 3 subnets

R       172.16.10.0/24 [120/2] via 192.10.10.1, 00:00:07, GigabitEthernet0/0

R       172.16.20.0/24 [120/2] via 192.10.10.1, 00:00:07, GigabitEthernet0/0

R       172.16.99.0/24 [120/2] via 192.10.10.1, 00:00:07, GigabitEthernet0/0

     192.10.10.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.10.10.0/24 is directly connected, GigabitEthernet0/0

L       192.10.10.2/32 is directly connected, GigabitEthernet0/0

R    192.10.20.0/24 [120/1] via 192.10.10.1, 00:00:07, GigabitEthernet0/0

R    192.168.10.0/24 [120/1] via 192.10.10.1, 00:00:07, GigabitEthernet0/0

     192.168.20.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.168.20.0/24 is directly connected, GigabitEthernet0/1

L       192.168.20.254/32 is directly connected, GigabitEthernet0/1

R-1#show ip protocols

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 13 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is not set

Incoming update filter list for all interfaces is not set

Redistributing: rip

Default version control: send version 2, receive 2

  Interface             Send  Recv  Triggered RIP  Key-chain

  GigabitEthernet0/0    22

  GigabitEthernet0/1    22

Automatic network summarization is not in effect

Maximum path: 4

Routing for Networks:

192.10.10.0

192.168.10.0

192.168.20.0

Passive Interface(s):

Routing Information Sources:

Gateway         Distance      Last Update

192.10.10.1          120      00:00:06

Distance: (default is 120)

Summary

This simple lab exercise shows that RIP (Routing Information Protocol) is a dynamic routing protocol that can be effectively utilised in a lab environment to test network connections and configurations.

RIP is efficient to be used in a small network with multiple routers. RIP involves a relatively simple configuration method, saving time in setup. Therefore, a network engineer performing a lab using the RIP routing protocol can be more focused on learning and experimentation.

The basic concept of hop count and period updates in the RIP protocol is simple and easy to understand and grasp. Also, RIP requires less CPU memory to process compared to more advanced dynamic routing protocols.

In conclusion, the easy concept of the RIP protocol allows for easier debugging and troubleshooting. Personally, I think the RIP is the perfect place to start and learn about routing, but also for the more advanced engineers, it is excellent to take charge of simple packet routing when all efforts are spent on experiments.