routing information protocol configuration

Satish Tiwary's picture
routing information protocol

This notes is all about how to configure RIP Version 1 and Version 2  on cisco routers.

This tutorial on RIP will make CCNA studentrs works more easier.Here we see how to configure rip version 1 and rip version2 on cisco routers.This tutorial consits of configuration.debugging and troubleshooting of Routing Information Protocol.

In our previous post we have learned how to configure static route on cisco routers.
We have seen that configuration is quite easy.But when the numbers of routers increases it becomes quite difficult to configure static routing.Therefore here we have tried to to used dynamic routing method.And our this post was dedicated to the topic how to configure and enable RIP version1 and RIP Version2 on cisco routers.As i have mentioned it in my previous post on rip tutorial that RIP Advertised  network addresses to other neighboring routers.Thus, it is a must that you know which among the available network addresses are needed to be advertised to neighboring routers for security reason.

RIP is one of most common routing protocol used by dynamic routing.It uses HOP Count as a method of advertising networks.

hop count measures how many routers a packet must pass through to travel from one point to another.

 

Configuring RIP Version 1 on a simple network.

  • Here we have take two routers Router0 and Router1.
  • Router0 and Router1 are connected with each other with serial port Se0/0/0 and Se0/0/0
  • Router0 and laptop0 is connected with each other with Ethernet port fa0/0.
  • Router1 and Laptop1 is connected with each other with Ethernet port fa0/0.
  • ip address of laptop0 is 10.0.0.2
  • ip address of lapto1 is 30.0.0.2

 

Steps wise explanation  to Configure RIP Routing on Cisco Routers
 

  • Enable RIP(Routing Information Protocol) In the user EXEC mode.
  • Then switch into privileged  mode and then type  config term to go to the global configuration mode.
  •  
  • Router RIP command must be entered to enable the RIP protocol.
  • Point to be noted that the prompt changes to (config-router)# means you’re working in routing configuration mode.
  • As here we are  working with classful networks, we don’t need to execute the command version since version 1 is the default version.Because rip does not support classless network. And also if we do not mention version number bydeault it will take version 1.

 

 

The Below commands will now show you how to configure Basic RIP Functionality.

Configure Routers to the specification given above.
  • Enable RIP routing on both routers.
  • Assign ip address to each ethernet and serial port.
  • After Routing complete you must be able to ping to non-directly connected network or hosts.

 

CONFIGURING ROUTER INTERFACES:

Interface Configuration On Router0:

Assign Ip address on ethernet Port and up network which is bydefault down.

 

Router>enable
Router#config terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#interface fastEthernet 0/0
Router(config-if)#ip address 10.0.0.1 255.0.0.0
Router(config-if)#no shutdown

 

Assign Ip address and clock rate on Serial  Port of Router0:

 

Router(config-if)#exit
Router(config)#interface serial 0/0/0
Router(config-if)#ip address 20.0.0.1 255.0.0.0
Router(config-if)#clock rate 64000
Router(config-if)#no shutdown
 
 
 
 
Interface Configuration on Router1
Assign Ip address on ethernet Port of Router1:
 
Router>enable
Router#config terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#int fa0/0
Router(config-if)#ip address 30.0.0.1 255.0.0.0
Router(config-if)#no shutdown
 

Assign Ip address on Serial Port of Router1:

 

Router(config-if)#exit
Router(config)#int serial 0/0/0
Router(config-if)#ip address 20.0.0.2 255.0.0.0
Router(config-if)#no shutdown
 

 

RIP version 1 configuration on Router0

 

Router>enable
Router#config terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#router rip
Router(config-router)#version 1
Router(config-router)#network 20.0.0.0
Router(config-router)#network 10.0.0.0
Router(config-router)#

 

Above command network 20.0.0.0 and network 10.0.0.0 tells the router to include all interfaces with ip address in this range.

 

RIP Version 1 Configuration on Router1

If you want to enable RIP on this router that is directly connected to the 20.0.0.0 and 30.0.0.0 network by using below commands.

 

Router>enable
Router#config terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#router rip
Router(config-router)#version 1
Router(config-router)#network 20.0.0.0
Router(config-router)#network 30.0.0.0
Router(config-router)#

 

Check the ip address of your machine and network connectivity:

Note:ipconfig coommand is used to see ip address on windows machine.

If you are using a linux machine you shoud use ifconfig command.

Subnet mask tells us how many bits of address is used as a network bit and how many bits are used as host bits.

An ip version 4 address consists of 32 bit address divided in to 4 octate.

here 10.0.0.2 is a CLASS A address.

 

 

PC>ipconfig
 
IP Address......................: 10.0.0.2
Subnet Mask.....................: 255.0.0.0
Default Gateway.................: 10.0.0.1


Now to test whether your connection and configuration is ok or not you can ping the remote ip to test connectivity.
 

PC>ping 20.0.0.2
 
Pinging 20.0.0.2 with 32 bytes of data:
 
Reply from 20.0.0.2: bytes=32 time=4ms TTL=127
Reply from 20.0.0.2: bytes=32 time=5ms TTL=127
Reply from 20.0.0.2: bytes=32 time=7ms TTL=127
Reply from 20.0.0.2: bytes=32 time=2ms TTL=127
 
Ping statistics for 20.0.0.2:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 2ms, Maximum = 7ms, Average = 4ms

 

 

 

Display RIP Related Information:

 

EXAMINE THE ROUTING TABLES:

 

How to Display the contents of the IP routing table?

show ip rip command can be used to verify RIP configuration:

 

 

Router#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
 
C    10.0.0.0/8 is directly connected, FastEthernet0/0
C    20.0.0.0/8 is directly connected, Serial0/0/0
R    30.0.0.0/8 [120/1] via 20.0.0.2, 00:00:27, Serial0/0/0

 

Network Engineers uses show and debug command to troubleshoot routing protocols.

 

Router#show ip route rip
R    10.0.0.0/8 [120/1] via 20.0.0.1, 00:00:24, Serial0/0/0

 

 

The Below command is used to see the RIP Database through which a network admin can see or troubleshoot.

Router#show ip rip database
10.0.0.0/8        directly connected, FastEthernet0/0
20.0.0.0/8        directly connected, Serial0/0/0
30.0.0.0/8       
    [1] via 20.0.0.2, 00:00:00, Serial0/0/0
Router#

 

 

To see the useful information about Intefaces and  address ranges which are involved in Routing Process use the below command:

show ip protocols command is also used to see or verify which routing protocol is running on the router.The debug ip rip, show ip protocols and show run commands are also used to verify whether ripv1 or ripv2 is running here on the router.

Router#show ip protocols
Routing Protocol is "rip"
Sending updates every 30 seconds, next due in 17 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 1, receive 1
  Interface             Send  Recv  Triggered RIP  Key-chain
  FastEthernet0/0       1     1     
  Serial0/0/0           1     1     
Automatic network summarization is in effect
Maximum path: 4
Routing for Networks:
    20.0.0.0
    30.0.0.0
Passive Interface(s):
Routing Information Sources:
    Gateway         Distance      Last Update
    20.0.0.1             120      00:00:05
Distance: (default is 120)
Router#

 

 

RIP DEBUGGING:

How to display RIP routing updates as they sent and received?

 

Router#debug ip rip

 

debug ip rip command is used here to display the RIP Routing Updates.

 

IP Along with it's physical address can be seen using show arp command:

Router#show arp
Protocol  Address          Age (min)  Hardware Addr   Type   Interface
Internet  30.0.0.1                -   0005.5E34.2C01  ARPA   FastEthernet0/0

 

 

 

RIP VERSION 2 CONFIGURATION USING 3 Routers

 

TOPOLOGY DIAGRAM OF RIPv2

Here you can see three users satish,sarath and slashroot are in three different network.Now if these users want to talk to each other they can't talk without routing.
so to make them communicating with each other possible here we are going to configure RIP version 2 on all these three routers.

 


From above diagram you can clearly see there are 5 diffrent network.

 

  • user satish with ip 10.0.0.2 reside in network 10.0.0.0/8
  • user sarath with ip  50.0.0.2 reside in network 50.0.0.0/8
  • user slashroot with ip 90.0.0.2 reside in network 90.0.0.0/8

 

Steps To configure:

  • connect network according to topology diagram.
  • assing ip and enable interfaces.
  • configure RIPv2 on all routers.
  • Verify or debug the routing updates using debug ip rip command.
  • Verify the routing tables.
  • verify network connectivity using ping command.

 

Now we are going to configure RIP version 2.

First we assign ip address on each pc then we assign ip address on each router port and then we enable network by

no shut and finally we set rip version 2 on each router.

 

First Router Ethernet port configuration:

Router>enable
Router#config terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#hostname linux
linux(config)#interface fastEthernet 0/0
linux(config-if)#ip address 10.0.0.1 255.0.0.0
linux(config-if)#no shutdown

 

 

First Router Serial Port Configuration:

 

linux(config)#interface serial 0/0/0
linux(config-if)#ip address 30.0.0.1 255.0.0.0
linux(config-if)#clock rate 64000
linux(config-if)#no shutdown
 

 

Ethernet and Serial port configuration on router second i.e middle router:

 

Router>enable
Router#configure terminal 
Router(config)#interface serial 0/0/0
Router(config-if)#ip address 30.0.0.2 255.0.0.0
Router(config-if)#no shut
 

 
Router(config-if)#exit
Router(config)#interface serial 0/0/1
Router(config-if)#ip address 70.0.0.1 255.0.0.0
Router(config-if)#clock rate 64000
Router(config-if)#no shut

 

Router(config)#interface fastEthernet 0/0
Router(config-if)#ip address 50.0.0.1 255.0.0.0
Router(config-if)#no shutdown

 

 

Ethernet and Serial Port Configuration on Last Router:

 

Router>enable
Router#configure terminal
Router(config)#hostname unix
unix(config)#interface fa0/0
unix(config-if)#ip address 90.0.0.1 255.0.0.0
unix(config-if)#no shutdown


 
unix(config-if)#exit
unix(config)#interface serial 0/0/0
unix(config-if)#ip address 70.0.0.2 255.0.0.0
unix(config-if)#no shutdown

 

 

configure and enable rip routing on router1

 

linux#configure terminal
linux(config)#router rip
linux(config-router)#versio
linux(config-router)#version 2
linux(config-router)#network 10.0.0.0
linux(config-router)#network 30.0.0.0
linux(config-router)#

 

 

configure an enable rip routing  on router 2

 

Router>enable
Router#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#router rip
Router(config-router)#version 2
Router(config-router)#network 30.0.0.0
Router(config-router)#network 50.0.0.0
Router(config-router)#network 70.0.0.0

 

 

configure and enable rip routing  on router 3

 

unix>enable
unix#configure
unix#configure terminal
unix(config)#router rip
unix(config-router)#version 2
unix(config-router)#network 90.0.0.0
unix(config-router)#network 70.0.0.0

 

 

linux#show run
Building configuration...
 
Current configuration : 637 bytes
!
version 12.4
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname linux
!
 
!
interface FastEthernet0/0
 ip address 10.0.0.1 255.0.0.0
 duplex auto
 speed auto
!
interface FastEthernet0/1
 no ip address
 duplex auto
 speed auto
 shutdown
!
interface Serial0/0/0
 ip address 30.0.0.1 255.0.0.0
 clock rate 64000
!
interface Serial0/0/1
 no ip address
 shutdown
!
interface Vlan1
 no ip address
 shutdown
!
router rip
 version 2
 network 10.0.0.0
 network 30.0.0.0
!
ip classless
!
!
line con 0
line vty 0 4
 login
!
!
!
end

 

 

Conclusion:

how to configure dynamic routing protocol?

ans:

linux(config)#router {protocol} [keyword]

{protocol}=RIP,IGRP,EIGRP,IS-IS,OSPF

 here we have used RIP

[protocol]=stands for autonomous system.

Rate this article: 
Average: 4.3 (13 votes)

Add new comment

Plain text

  • No HTML tags allowed.
  • Web page addresses and e-mail addresses turn into links automatically.
  • Lines and paragraphs break automatically.
CAPTCHA
This question is for testing whether or not you are a human visitor and to prevent automated spam submissions.