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.3 Routing with static routes

In this section you will look at why the network path still isn’t complete, and think about why the ping packet still doesn’t get to its destination and back. You’ll look at how to put static routes into the routers so that they know where to send their packets.

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

Routing with default routes 2

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


The reason why the ping from PC1 to PC3 still does not work is because we don’t have a return path created in the reverse direction for the traffic to come back.

To solve this we need to put the default static route command into Router2 as well, to direct unknown traffic from Router2 to be sent to Router1. We will put the command ip route Router2, which will direct traffic for unknown networks in Router2 back to FRouter1’s address.

OK, so let’s try the ping again. Now when we ping from PC1 we should expect a reply.

From this we have learned that you need to set up both the outward path and a return path between the two routers. Default static routes are really only useful where there is only one router connected to another – such as in the network topology we have used here, or with your home or business broadband connection. Default static routes are useful where there is only one choice of destination to send the traffic to.

With bigger networks we need a different approach to setting up the routing tables. One solution could be to use static routes – where we set up the path to each destination network manually.

First we are going to remove the default static routes we created on both Router1 and Router2. To do this we need to execute the same command we used to put the default route in, but enter the word ‘no’ at the beginning of the command.

OK, let’s look at the following command on Router1: ip route

This has put in a path to network (with a subnet mask of sending the traffic to the IP address of – which is Router2’s address. We must not forget to put in the return path so that Router2 knows how to send the ping back to PC1. For this we will use the command ip route

We now have a path out from PC1 to PC3, and a return back to the starting point. If we now try pinging PC1 from PC3, we can see that this works nicely. It should also work the other way round, so next we will ping PC1 from PC3. This works properly too.

OK, let’s try something else. Let’s see if PC3 can ping PC2. If we ping from PC3, we get this result. We can see that it has failed. The reply was from (which is Router2) and it says that the destination host is unreachable. Let’s look at Router2’s routing table to see what is going on: show ip route shows that the new network we manually entered to and with a mask of (which is represented as /24) is in the routing table.

We need to think about why PC3 and PC1 can ping each other, but not PCs 3 and 2.

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

Activity 3 Think about

5 minutes

At the end of the demonstration in the second video, PC3 could ping PC1 and vice versa, but PC3 couldn’t ping PC2. Can you work out why this is happening? Choose the best answer from the options below.


PC3 is incorrectly set up.


PC2 is incorrectly set up.


There is no route in Router 2’s routing table pointing to PC2’s network.


PC2 has the wrong IP address configured on it.

The correct answer is c.


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, we offer two introductory routes to our qualifications. You could either choose to start with an Access module, or a module which allows you to count your previous learning towards an Open University qualification. Read our guide on Where to take your learning next for more information.

Not ready for formal University study? Then browse over 1000 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 prospectus371