Discovering computer networks: hands on in the Open Networking Lab
Discovering computer networks: hands on in the Open Networking Lab

Start this free course now. Just create an account and sign in. Enrol and complete the course for a free statement of participation or digital badge if available.

Free course

Discovering computer networks: hands on in the Open Networking Lab

14.5 Routing with dynamic routes

In this section you will look at how dynamic routing protocols can be used to automate the process so that static routes don’t have to be put in place for all of our networks.

Watch the video below, which is about 4 minutes long.

Dynamic routing

Download this video clip.Video player: 79_title_tbc.mp4
Skip transcript

Transcript

The idea of static routes works nicely for very small numbers of routers, but what happens if the network is very large? There needs to be a way of making routers learn about each other automatically rather than the network administrator having to keep entering the details manually each time the network changes in some way.

This type of routing is called dynamic routing as opposed to static routing.

There are several routing protocols which have been developed to allow routers to learn about each other’s networks. Examples of these protocols include open-source protocols such OSPF and BGP, but we are going to look at a simple routing protocol called RIP (Routing Information Protocol) as it is about the simplest one to setup and demonstrate in the lab.

First we need to remove all the static routing we entered previously. Again we will do this by re-entering the ip route commands with a ‘no’ in front of them.

To configure RIP on each router we need to start the RIP protocol going with the command router rip. There are two versions of the RIP protocol for IPv4 – we need to use version 2 as version 1 is now obsolete. This is why we normally type the command version 2 whenever we type the router ripcommand.

To finish the configuration of RIP, we need to enter a network statement for each network that is local to our routers.

On Router1 enter the following statements: network 192.168.1.0, network 192.168.2.0and network 10.10.10.0on Router1. We now need to go to the command-line interface of Router2 and enter network 172.16.1.0and network 10.10.10.0.

If we now do a show ip route command on each router, we will see that there are some new routes in the routing table with a capital R next to them. This shows that they have been learned by the RIP protocol.

Just to prove everything is working, we will now do some pings from PC to PC to see the response. We can see that PC3 can ping PC1, and PC3 can also ping PC2.

Just to prove that routing protocols make our lives simpler than doing all the work manually, we are now going to add in a new network. We will create PC4 and join it to the gigabit 0/2 interface of Router2. We will then add the IP address of PC4 as 172.16.2.2.

We then give the gigabit 0/2 interface the IP address of 172.16.2.1, and then not forget to switch the interface on.

All we need to do to make this new network show up round the whole system, is to finally enter the new network statement of network 172.16.2.0 on Router2. To do this, type router ripto enter the RIP configuration mode. We do not need to type version 2again as it has already been entered previously. We then enter the command network 172.16.2.0.

If we now go to Router1 and look at its routing table again, we will now see that the new network has appeared in the routing table and there are now two networks which have been learned by RIP.

You should now have some understanding about the roles of static routing and dynamic routing, and have some idea of the situations in which you would use each type of routing.

End transcript
 
Interactive feature not available in single page view (see it in standard view).

Activity 5 Try it out

10 minutes

Open PT Anywhere [Tip: hold Ctrl and click a link to open it in a new tab. (Hide tip)] in a new tab or window so you can read these instructions.

This activity starts off with the same layout as in the previous activity in this session, except this time the IP addresses on all of the devices have already been configured for you.

Your task is to enable dynamic routing (using RIP) on both of the routers.

  1. Verify that PC1 cannot ping PC3 (ping 172.16.1.2).
  2. On the routers (Router 1 and Router 2) enter the commands in the table below.
DeviceCommands to enter
Router 1

enable

configure terminal (abbreviate this to conf t)

router rip

version 2

network 192.168.1.0

network 192.168.2.0

network 10.10.10.0

Router 2

enable

configure terminal (abbreviate this to conf t)

router rip

version 2

network 172.16.1.0

network 172.16.2.0

network 10.10.10.0

  1. Verify that PC1 can ping PC3 (ping 172.16.1.2) and PC4 (ping 172.16.2.2).
  2. Check to see if PC3 can ping PC1 (ping 192.168.1.2) and PC2 (ping 192.168.2.2).

You have now configured RIP on the two routers and verified that each PC can see (ping) all of the other PCs successfully. (Note: as above, if you were to build this network from scratch in PT Anywhere then you would need to place a switch in the link between Router 1 and Router 2, and in the links between each PC and router. This is because PT Anywhere does not provide crossover cables.)

OPNL_1

Take your learning further

Making the decision to study can be a big step, which is why you'll want a trusted University. The Open University has 50 years’ experience delivering flexible learning and 170,000 students are studying with us right now. Take a look at all Open University courses.

If you are new to university level study, find out more about the types of qualifications we offer, including our entry level Access courses and Certificates.

Not ready for University study then browse over 900 free courses on OpenLearn and sign up to our newsletter to hear about new free courses as they are released.

Every year, thousands of students decide to study with The Open University. With over 120 qualifications, we’ve got the right course for you.

Request an Open University prospectus