General information on “Static route”:
- A static route is a manually configured route not learned dynamically by a routing protocol
- The target of the default route should be the next-hop IP address (exit-interface only is possible but not recommended)
- If the next-hop is an IPv6 link-local address, then a exit-interface is mandatory
- By default, the AD for a statically configured route is 1 but can be changed
Static route types:
- “Standard” static route: A manually configured route used to reach a network.
- “Default” static route: Target network is 0.0.0.0/0 (IPv4) or ::/0 (IPv6).
- “Floating” static route: A manually configured BACKUP route used to reach a network. Configured when a routing protocol is used as well. AD should be set +1 than the AD of the routing protocol.
- “Summary” static route: Used when several target networks are contiguous. Instead of creating four separate routes to 172.16.0.0/24, 172.16.1.0/24, 172.16.2.0/24, 172.16.3.0/24 a single route of 172.16.0.0/22 can be created.
“Static Routing” CLI configuration commands:
## Configuring a static IPv4 route Router(config)# ip route <network> <mask> [<next-hop-ip> |<exit-if>] [<ad>] ## Configuring a static IPv6 route Router(config)# ipv6 route <network> [<next-hop-ip> | <exit-if>][<ad>]
“Static Routing” CLI show commands:
## Showing configured static IPv4 routes Router# show ip static-route ## Showing configured static IPv6 routes Router# show ipv6 static-route