How to Configure Static Routes
What is Static Route?
Static routing occurs when you, the network administrator
manually add or configure routes on each router interface with IP addresses. This is no simple
task, especially when you are administering a large network. In as much as its
a complex task, there are benefits of static routes:
i.
Bandwidth usage between router is at a minimum,
none in some cases.
ii. There is no overhead on the router CPU.
iii.
It adds security due to choice of route
configuration by the administrator.
iv.
It reduces the amount of routes found in the
routing table.
Disadvantages of Static Routes:
i.
Takes too much man hours for configuration
especially in a large network.
ii. Too complex and can sometime be confusing during
troubleshooting.
Static Router command syntax: ip
Ip route
{destination network address} {mask}
{next hop address or exit interface}
We will use the following network topology as an example.
All necessary interfaces had been configured with IP address.
Remember the Static Router command syntax:
Ip route
{destination network address} {mask}
{next hop address or exit interface}
Static Route configuration on HQ router:
HQ(config)#ip route 172.16.10.0 255.255.255.0 10.10.11.2
HQ(config)#interface serial 0/0/0
HQ(config-if)#clock rate 64000
HQ(config-if)#end
HQ#
Command syntax explained from the example configuration
above:
The ip route:
this command creates the static route and tells the router that this is a static
route.
172.16.10.0:
This is the remote network we want to send the packet to.
255.255.255.0: This
is the mask of the remote network.
10.10.11.2:
this is the next hop router address we are sending packet to.
Here, the exit interface could be used in the place of
next hop address:
HQ(config)#ip route 172.16.10.0 255.255.255.0 se0/0/0
HQ(config)#end
Verify your
configuration from the routing table:
HQ#show ip route
[output omitted]
10.0.0.0/30 is
subnetted, 1 subnets
C 10.10.11.0
is directly connected, Serial0/0/0
172.16.0.0/24
is subnetted, 1 subnets
S 172.16.10.0
[1/0] via 10.10.11.2
C
192.168.30.0/24 is directly connected, FastEthernet0/0
HQ#
The S represents the static route with the administrative
distance of 1. The router gives priority to static routes over dynamic routes,
where 0 is best and 255 is worst!
To verify the connectivity, Ping from PC 1 to
PC 5
PC1
PC1>ping 172.16.10.2
Pinging 172.16.10.2 with 32 bytes of data:
Reply from 172.16.10.2: bytes=32 time=140ms TTL=126
Reply from 172.16.10.2: bytes=32 time=140ms TTL=126
Reply from 172.16.10.2: bytes=32 time=156ms TTL=126
Reply from 172.16.10.2: bytes=32 time=156ms TTL=126
Ping statistics for 172.16.10.2:
Packets: Sent =
4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum =
140ms, Maximum = 156ms, Average = 148ms
Also, Ping from PC 7 to PC 3
PC7>ping 192.168.30.4
Pinging 192.168.30.4 with 32 bytes of data:
Reply from 192.168.30.4: bytes=32 time=156ms TTL=126
Reply from 192.168.30.4: bytes=32 time=156ms TTL=126
Reply from 192.168.30.4: bytes=32 time=109ms TTL=126
Reply from 192.168.30.4: bytes=32 time=135ms TTL=126
Ping statistics for 192.168.30.4:
Packets: Sent =
4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum =
109ms, Maximum = 156ms, Average = 139ms
PC7>