Google

Thursday, November 15, 2007

Configuring RIP

Before configuring RIP, or any IP routing protocol, IP routing must be enabled on the router. To do this first enter global configuration mode. Then enter the command:
ip routing

If you forget to do this you will get an error when you try to enable the RIP protocol.

Now from the global configuration prompt type:
router rip

This will create a RIP routing process on the router. It will also give you a new prompt, the router configuration prompt:

routername(config-router)#

From this prompt you can enter configuration commands to define the RIP process for this router. To get back to this prompt to reconfigure RIP at a later time simply type router rip again.

You now need to tell the router which networks it should advertise routes for. This is done with the command
network network_address

where network_address is the IP address for the network you wish to add. For example:

rip2(config-router)#network 156.156.128.0

Would tell the router to advertise the network 156.156.128.0. You should use the network command for each of the networks that the router is connected to and is a part of the RIP network.

Unless this router is the exit router it will not know how to get to locations outside of the AS. In order to reach these destinations we need to give the router a default route over which the router will send packets that it does not have a route for in the routing table. Type exit to return to global configuration mode. We will now add a static route to the routing table using the command
ip route prefix mask address

where prefix is the address of the network you are creating a route for, mask is the mask for this network, and address is the IP address of the interface you are routing the packets to. For all of the eigrp routers except the exit router (the one connected to the core) use the following command to create the default route.

rip2(config)# ip route 0.0.0.0 0.0.0.0 156.156.11.1

You have now completed a basic configuration of RIP on the router! There are many more configuration options available to you, such as modifying the metrics for each of the interfaces, adjusting the timers and delays for when updates are sent, routes are declared invalid, etc. You can also turn on or off various features such as authentication and split-horizon. To find out more about other commands just type a question mark at the router configuration prompt or read the references listed at the end of the page.
It would be a good idea to save your configuration! To do this type the following at the privileged mode prompt:
write

This will save the currently running configuration to the NVRAM. If the router gets rebooted for some reason ( it shouldn't happen, but it could!) it will use the configuration that is stored in the NVRAM. So save often!

You can view the currently running configuration by typing:

write terminal

This will print the configuration to the screen, but it will not save it.

Verifying Your RIP configuration

Once you have configured RIP on all four of the routers in the AS and enabled the interfaces you will want to verify that your setup indeed working.

One easy way to check and see if the packets are getting routed is to ping interfaces on other routers. This done by typing:
ping address

This command can be used at either the user mode or privileged mode prompts. You should be able to get a reply to a ping from every interface on each of the routers. This a simple way to verify that you can reach the other routers within the network.

You can also view the routers current routing table by using the command:
show ip route

This command can be used at either the user mode or privileged mode prompts. The command will give you a table listing all of the routes currently in the routing table. Each entry in the table tells you the following:

The protocol the route was received from - for RIP it will be an R. C means that it is directly connected to the router.
Route Type - for RIP this wil probably be blank
Destination Address - The address of the remote network the route is for.
Administrative Distance
Metric
Address of the Next Hop
Interface used to reach the Next Hop
There are several useful subcommands as well:

show ip route rip

This command will only show the RIP routes in the table.

show ip route network

This command will give detailed routing information about the specified network.

Another useful source of information is the command series show ip rip
This will give you lots of information about the RIP process running on the router. You can explore the various commands on your own by typing:
show ip rip

No comments:

 
Google