Static Routes Lab
Basic static routes lab. This lab builds upon the Connected Routes Lab so if you haven't already check it out first.
Objectives:
- Add static routes on R1 for 10.1.2.0/24 via R2 and 10.1.3.0/24 via R3
- Add static routes on R2 for 10.1.1.0/24 via R1 and 10.1.3.0/24 via R3
- Add static routes on R3 for 10.1.1.0/24 via R1 and 10.1.2.0/24 via R2
- Verify connectivity.
- Verify the routing tables and observe the static routes.
Solution for R1 Only:
Add Static Routes on R1 for 10.1.2.0/24 via R2 and 10.1.3.0/24 via R3
R1(config)#ip route 10.1.2.0 255.255.255.0 10.1.128.252 R1(config)#ip route 10.1.3.0 255.255.255.0 10.1.130.252
Verify Connectivity
R1#ping 10.1.2.252 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.1.2.252, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 8/19/36 ms R1#ping 10.1.3.253 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.1.3.253, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 8/15/24 ms
Verify the Routing Tables and Observe the Static Routes
R1#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, 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
10.0.0.0/24 is subnetted, 5 subnets
S 10.1.3.0 [1/0] via 10.1.130.252
S 10.1.2.0 [1/0] via 10.1.128.252
C 10.1.1.0 is directly connected, Ethernet0/2
C 10.1.130.0 is directly connected, Ethernet0/1
C 10.1.128.0 is directly connected, Ethernet0/0As you can see there are now two additional routes in addition to our directly connected routes signified by the letter 'S' for static.
Two additional pointers you should keep in mind for the exam. If the interface which is connected to the subnet of a next hop router is not in an up/up state, the route will not be shown in the routing table. Here I've shutdown R1's ethernet 0/0 interface which has removed the route to the 10.1.2.0/24 network from the routing table. As soon as the interface comes up again it will be re-inserted into the routing table.
R1(config)#interface ethernet 0/0
R1(config-if)#shutdown
R1#sh ip route
!!!!! TRUNCATED !!!!!
Gateway of last resort is not set
10.0.0.0/24 is subnetted, 3 subnets
S 10.1.3.0 [1/0] via 10.1.130.252
C 10.1.1.0 is directly connected, Ethernet0/2
C 10.1.130.0 is directly connected, Ethernet0/1
Secondly if the appropriate routes are only added to R1 but not to R2 or R3, return traffic to R1's LAN segment will fail as shown using the extended ping command from EXEC mode, and setting the source address as R1's LAN segment IP, 10.1.1.251:
R1#ping Protocol [ip]: Target IP address: 10.1.3.253 Repeat count [5]: Datagram size [100]: Timeout in seconds [2]: Extended commands [n]: y Source address or interface: 10.1.1.251 Type of service [0]: Set DF bit in IP header? [no]: Validate reply data? [no]: Data pattern [0xABCD]: Loose, Strict, Record, Timestamp, Verbose[none]: Sweep range of sizes [n]: Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.1.3.253, timeout is 2 seconds: Packet sent with a source address of 10.1.1.251 ..... Success rate is 0 percent (0/5)
Default Routes
Rather then create a dedicated lab for default routes i'll show you a quick example here. Lets assume that we have configured R1 as shown. Picture R1 as the next hop router to the rest of the network or even out to the Internet. On R2 we'll configure a default route using R1 as gateway. Doing this means we also do not need a static route to be configured for the 10.1.1.0/24 network on R2.
R2(config)#ip route 0.0.0.0 0.0.0.0 10.1.128.251
R2#sh ip route
Codes: C - connected, S - static, 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
i - IS-IS, su - IS-IS summary, 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 10.1.128.251 to network 0.0.0.0
10.0.0.0/24 is subnetted, 3 subnets
C 10.1.2.0 is directly connected, Ethernet0/2
C 10.1.129.0 is directly connected, Ethernet0/1
C 10.1.128.0 is directly connected, Ethernet0/0
S* 0.0.0.0/0 [1/0] via 10.1.128.251
R2#ping 10.1.1.251
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.1.1.251, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/8 msAs you can see there is now Gateway of last resort listed, and you can also see the "candidate default" route signified by the '*' in the routing table




