0

Network Topology

For the network topology attached in the image, a static route is configured with ip route 10.10.10.0 255.255.255.252 Ethernet0/0. Referring to the Topology and the output from the show ip route command, the OSPF route has the prefix /30. And, the configured static route has a prefix /29.

Considering IOS's routing priorities, I think despite OSPF having a higher AD than static and not configuring a floating static, the OSPF route would be preferred over the static one because the OSPF route is more specific with a prefix /30 as compared to the less specific static route with prefix /29.

However, the source of this question doesn't talk about the prefix length but just says OSPF has an AD that's greater than a static route's AD and hence, the static route would be preferred!

The question has the following options (It's multiple choice):

A) The gateway of last resort will be the Eth0/0 interface on R1
B) Routing Loops or performance problems will occur as R1 points back to itself
C) Static Route will be used as a backup if OSPF goes down
D) The OSPF route will be replaced by the static route

As I explained earlier, I think Option C is right (despite not configuring a floating static). But, the original source of the question states Option D as the answer.

1 Answer 1

4

252 is a /30.

Static routes have a higher preference than dynamic routes (by default, as in the example.) If you don't want that, set the metric for the static route higher than the dynamic route.

Static routes have a default administrative distance of 1. A router prefers a static route to a dynamic route because the router considers a route with a low number to be the shortest. If you want a dynamic route to override a static route, you can specify an administrative distance for the static route. For example, if you have two dynamic routes with an administrative distance of 120, you would specify an administrative distance that is greater than 120 for the static route if you want the dynamic route to override the static route.

Cisco

(See Also: Configure Route Selection for Routers

2
  • Note: very old IOS (that no one should ever see again) may prefer static no matter what.
    – Ricky
    Commented Jul 22, 2023 at 10:35
  • 252 is /30. That's what I did wrong! And yes, Static Routes do have preference over Dynamic ones. Thanks! Commented Jul 22, 2023 at 11:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.