The Ultimate Resource for the CCNA 200-301 Exam (Click Here)
Configure Floating Static Routes
Configure Floating Static Routes

Configure Floating Static Routes

Configure Floating Static Routes
5

Summary

This topic configure a floating static route to provide a backup connection.. Start learning CCNA 200-301 for free right now!!

Note: Welcome: This topic is part of Module 15 of the Cisco CCNA 2 course, for a better follow up of the course you can go to the CCNA 2 section to guide you through an order.

Floating Static Routes

As with the other topics in this module, you will learn how to configure IPv4 and IPv6 floating static routes and when to use them.

Another type of static route is a floating static route. Floating static routes are static routes that are used to provide a backup path to a primary static or dynamic route, in the event of a link failure. The floating static route is only used when the primary route is not available.

To accomplish this, the floating static route is configured with a higher administrative distance than the primary route. The administrative distance represents the trustworthiness of a route. If multiple paths to the destination exist, the router will choose the path with the lowest administrative distance.

For example, assume that an administrator wants to create a floating static route as a backup to an EIGRP-learned route. The floating static route must be configured with a higher administrative distance than EIGRP. EIGRP has an administrative distance of 90. If the floating static route is configured with an administrative distance of 95, the dynamic route learned through EIGRP is preferred to the floating static route. If the EIGRP-learned route is lost, the floating static route is used in its place.

In the figure, the branch router typically forwards all traffic to the HQ router over the private WAN link. In this example, the routers exchange route information using EIGRP. A floating static route, with an administrative distance of 91 or higher, could be configured to serve as a backup route. If the private WAN link fails and the EIGRP route disappears from the routing table, the router selects the floating static route as the best path to reach the HQ LAN.

Floating Static Routes
Floating Static Routes

By default, static routes have an administrative distance of 1, making them preferable to routes learned from dynamic routing protocols. For example, the administrative distances of some common interior gateway dynamic routing protocols are:

  • EIGRP = 90
  • OSPF = 110
  • IS-IS = 115

The administrative distance of a static route can be increased to make the route less desirable than that of another static route or a route learned through a dynamic routing protocol. In this way, the static route “floats” and is not used when the route with the better administrative distance is active. However, if the preferred route is lost, the floating static route can take over, and traffic can be sent through this alternate route.

Configure IPv4 and IPv6 Floating Static Routes

IP floating static routes are configured by using the distance argument to specify an administrative distance. If no administrative distance is configured, the default value (1) is used.

Refer to the topology in the figure and the ip route and ipv6 route commands issued on R1. In this scenario, the preferred default route from R1 is to R2. The connection to R3 should be used for backup only.

Configure IPv4 and IPv6 Floating Static Routes
Configure IPv4 and IPv6 Floating Static Routes
R1(config)# ip route 0.0.0.0 0.0.0.0 172.16.2.2
R1(config)# ip route 0.0.0.0 0.0.0.0 10.10.10.2 5
R1(config)# ipv6 route ::/0 2001:db8:acad:2::2
R1(config)# ipv6 route ::/0 2001:db8:feed:10::2 5

R1 is configured with IPv4 and IPv6 default static routes pointing to R2. Because no administrative distance is configured, the default value (1) is used for these static routes. R1 is also configured with IPv4 and IPv6 floating static default routes pointing to R3 with an administrative distance of 5. This value is greater than the default value of 1 and therefore; this route floats and is not present in the routing table unless the preferred route fails.

The show ip route and show ipv6 route output verifies that the default routes to R2 are installed in the routing table. Note that the IPv4 floating static route to R3 is not present in the routing table.

R1# show ip route static | begin Gateway
Gateway of last resort is 172.16.2.2 to network 0.0.0.0

S*   0.0.0.0/0 [1/0] via 172.16.2.2
R1# show ipv6 route static | begin S : 
S   ::/0 [1/0]
     via 2001:DB8:ACAD:2::2
R1#

Use the show run command to verify that floating static routes are in the configuration. For example, the following command output verifies that both IPv6 static default routes are in the running configuration.

R1# show run | include ipv6 route
ipv6 route ::/0 2001:db8:feed:10::2 5
ipv6 route ::/0 2001:db8:acad:2::2
R1#

Test the Floating Static Route

In the figure, what would happen if R2 failed?

Configure IPv4 and IPv6 Floating Static Routes
Configure IPv4 and IPv6 Floating Static Routes

To simulate this failure, both serial interfaces of R2 are shut down, as shown in the configuration.

R2(config)# interface s0/1/0
R2(config-if)# shut
*Sep 18 23:36:27.000: %LINK-5-CHANGED: Interface Serial0/1/0, changed state to administratively down
*Sep 18 23:36:28.000: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/1/0, changed state to down
R2(config-if)# interface s0/1/1
R2(config-if)# shut
*Sep 18 23:36:41.598: %LINK-5-CHANGED: Interface Serial0/1/1, changed state to administratively down
*Sep 18 23:36:42.598: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/1/1, changed state to down

Notice that R1 automatically generates messages indicating that the serial interface to R2 is down.

R1#
*Sep 18 23:35:48.810: %LINK-3-UPDOWN: Interface Serial0/1/0, changed state to down
R1#
*Sep 18 23:35:49.811: %LINEPROTO-5-UPDOWN: Line protocol on Interface Serial0/1/0, changed state to down
R1#

A look at the IP routing tables of R1 verifies that the floating static default routes are now installed as the default routes and are pointing to R3 as the next-hop router.

R1# show ip route static | begin Gateway
Gateway of last resort is 10.10.10.2 to network 0.0.0.0
S*    0.0.0.0/0 [5/0] via 10.10.10.2
R1# show ipv6 route static | begin :: 
S   ::/0 [5/0] 
     via 2001:DB8:FEED:10::2
R1#

Syntax Checker – Configure Floating Static Route

Configure and verify floating static routes based on the specified requirements.

Configure IPv4 and IPv6 Floating Static Routes
Configure IPv4 and IPv6 Floating Static Routes
  • Configure an IPv4 default static route on R3 using the next-hop address 192.168.1.2.
R3(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
  • Configure an IPv4 default static route on R3 using the next-hop address 10.10.10.1 with an administrative distance of 5.
R3(config)#ip route 0.0.0.0 0.0.0.0 10.10.10.1 5
  • Configure an IPv6 default static route on R3 using the next-hop address 2001:db8:cafe:1::2
R3(config)#ipv6 route ::/0 2001:db8:cafe:1::2
  • Configure an IPv6 default route on R3 using the next-hop address 2001:db8:feed:10::1 with an administrative distance of 5.
R3(config)#ipv6 route ::/0 2001:db8:feed:10::1 5
  • Exit configuration mode and display the IPv4 routing table.
R3(config)#exit
\*Sep 20 02:55:53.327: %SYS-5-CONFIG\_I: Configured from console by console
R3#show ip route
Codes: L - local, 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, H - NHRP, l - LISP   
\+ - replicated route, % - next hop override   
  
Gateway of last resort is 192.168.1.2 to network 0.0.0.0  
  
S\* 0.0.0.0/0 \[1/0\] via 192.168.1.2
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        10.10.10.0/24 is directly connected, Serial0/1/0
L        10.10.10.2/32 is directly connected, Serial0/1/0
      192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.1.0/24 is directly connected, Serial0/1/1
L        192.168.1.1/32 is directly connected, Serial0/1/1
      192.168.2.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.2.0/24 is directly connected, GigabitEthernet0/0/0
L        192.168.2.1/32 is directly connected, GigabitEthernet0/0/0
  • Display the IPv6 routing table.
R3#show ipv6 route
IPv6 Routing Table - default - 8 entries
Codes: C - Connected, L - Local, S - Static, U - Per-user Static route
       B - BGP, R - RIP, H - NHRP, I1 - ISIS L1
       I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary, D - EIGRP
       EX - EIGRP external, ND - ND Default, NDp - ND Prefix, DCE - Destination
       NDr - Redirect, RL - RPL, O - OSPF Intra, OI - OSPF Inter
       OE1 - OSPF ext 1, OE2 - OSPF ext 2, ON1 - OSPF NSSA ext 1
       ON2 - OSPF NSSA ext 2, a - Application
S   ::/0 \[1/0\]
     via 2001:DB8:CAFE:1::2
C   2001:DB8:CAFE:1::/64 \[0/0\]
     via Serial0/1/1, directly connected
L   2001:DB8:CAFE:1::1/128 \[0/0\]
     via Serial0/1/1, receive
C   2001:DB8:CAFE:2::/64 \[0/0\]
     via GigabitEthernet0/0/0, directly connected
L   2001:DB8:CAFE:2::1/128 \[0/0\]
     via GigabitEthernet0/0/0, receive
C   2001:DB8:FEED:10::/64 \[0/0\]
     via Serial0/1/0, directly connected
L   2001:DB8:FEED:10::2/128 \[0/0\]
     via Serial0/1/0, receive
L   FF00::/8 \[0/0\]
     via Null0, receive

You have successfully configured and verified floating static routes.

Glossary: If you have doubts about any special term, you can consult this computer network dictionary.

Ready to go! Keep visiting our networking course blog, give Like to our fanpage; and you will find more tools and concepts that will make you a networking professional.