Static Routing (2024)

You may have noticed that it’s the dynamic routing protocols that get all the glory. Since I like rooting (routing?) for the underdog, let’s talk about static routes!

As you may recall, a router has three methods for learning a route. A route can appear in the routing table if it is:


  • Connected – directly attached

  • Dynamic - learned via a routing protocol

  • Static – configured by a person

A static route is a route that manually inserted into the routing table. Static routes appear in the routing table as “S” routes, and are often used:


  • When there is only one path to reach a destination

  • As a backup route to a destination


Static routes are created in global config mode, and require a destination prefix and a way to get there. For example, let’s say that our router’s Serial 1/1 interface, with an IP address of 192.168.1.5/30, has a point-to-point link to another router’s Serial 2/2, with IP address 192.168.1.6/30. We’ve been told that we can reach the 10.2.3.0/24 subnet via the neighbor router. To configure a static route, the command could be:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 192.168.1.6

Note that the next hop address is our neighbor’s address (not ours). In the case of a point-to-point serial link, you also have the option of using the outbound interface, like this:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 serial 1/1

Note that when the interface option is specified, it’s our interface (not the neighbor’s). The interface option only works with point-to-point links, such as serial links running HDLC or PPP. The interface option will not work with multi-point interfaces, such as LANs, Frame Relay, or ATM. This is because the multi-point topologies require a Layer 2 address (MAC, DLCI, or VPI/VCI, for example), and it’s necessary to have the next-hop’s IP address to resolve this.

If you configure a static route using the outbound interface on a multi-access link (such as Ethernet or Frame Relay), you won’t get a syntax error, but routing will fail. In fact, “debug ip packet” will reveal “encapsulation failed” for packets following that route, indicating that the router was unable to build the frame header due to lack of a Layer-2 destination address. You must use the “next-hop” option when configuring a static route on a multi-access media.

Note that although they appear in the running config as soon as they are created, by default a static route will only be inserted into the routing table if the router believes that the next hop is actually reachable. In other words, for the static route to appear in the routing table, the interface used to reach the next hop must be “up/up”.

Contrary to what you might read (including in some Cisco documentation), the default administrative distance (AD) for a static route is one, regardless of whether the next hop or outbound interface is used. By default, the only thing that beats a static route is a connected route, with an AD of zero.

You can however, change the AD of a static route. Let’s say that your router is learning the route to 10.2.3.0/24 via OSPF, which has a default AD of 110. Now suppose that you configure a static route to 10.2.3.0/24 with an AD of 250, like this:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 192.168.1.6 250

If the link is point-to-point, you could also do it like this:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 serial 1/1 250

Note that the value following the next hop, or outbound interface, is the AD for the static route. Since when choosing a route it’s the low AD that wins, as long as the route is being learned by OSPF, it’s the OSPF route that will appear in the routing table (110 beats 250). If the OSPF route is no longer available, then the static route will appear in the routing table. This type of static route is referred to as a “floating” static route, and it is sometimes used for backup links.

You can also specify a “tag” when configuring a static route. This is done by using the keyword “tag”, like this:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 192.168.1.6 tag 1000

The tag can then be matched with a route map (a glorified access list that allows you to permit, deny, and change parameters of routing advertisem*nts). And, of course, you can also specify a tag along with an admin distance:


  • Router(config)#ip route 10.2.3.0 255.255.255.0 serial 1/1 250 tag 1000

Static routes have other options as well. No sense letting the dynamic protocols have all the fun!

Author: Al Friebe

Static Routing (2024)
Top Articles
How to Remove Tape Residue - Surface Shields
How To Keep a House Warm in Winter
Algebra Calculator Mathway
Google Sites Classroom 6X
Byrn Funeral Home Mayfield Kentucky Obituaries
Chalupp's Pizza Taos Menu
United Dual Complete Providers
Zachary Zulock Linkedin
Ohiohealth Esource Employee Login
Sotyktu Pronounce
Healing Guide Dragonflight 10.2.7 Wow Warring Dueling Guide
Nyuonsite
Define Percosivism
Simpsons Tapped Out Road To Riches
NBA 2k23 MyTEAM guide: Every Trophy Case Agenda for all 30 teams
My Homework Lesson 11 Volume Of Composite Figures Answer Key
I Saysopensesame
A Person That Creates Movie Basis Figgerits
Talkstreamlive
Breckiehill Shower Cucumber
Jayme's Upscale Resale Abilene Photos
Preggophili
TMO GRC Fortworth TX | T-Mobile Community
Login.castlebranch.com
Penn State Service Management
Craigslist Boerne Tx
Housing Intranet Unt
Otis Inmate Locator
Nurtsug
Indiana Jones 5 Showtimes Near Jamaica Multiplex Cinemas
How to Draw a Bubble Letter M in 5 Easy Steps
What Time Does Walmart Auto Center Open
The Pretty Kitty Tanglewood
Diana Lolalytics
What Time Is First Light Tomorrow Morning
New Gold Lee
Mohave County Jobs Craigslist
Is The Nun Based On a True Story?
Immobiliare di Felice| Appartamento | Appartamento in vendita Porto San
QVC hosts Carolyn Gracie, Dan Hughes among 400 laid off by network's parent company
Todd Gutner Salary
Craigslist Com St Cloud Mn
4k Movie, Streaming, Blu-Ray Disc, and Home Theater Product Reviews & News
Matt Brickman Wikipedia
Zeeks Pizza Calories
Bank Of America Appointments Near Me
Dayton Overdrive
Craigslist Marshfield Mo
Makemkv Key April 2023
A Snowy Day In Oakland Showtimes Near Maya Pittsburg Cinemas
Jasgotgass2
Bob Wright Yukon Accident
Latest Posts
Article information

Author: Dean Jakubowski Ret

Last Updated:

Views: 5893

Rating: 5 / 5 (70 voted)

Reviews: 93% of readers found this page helpful

Author information

Name: Dean Jakubowski Ret

Birthday: 1996-05-10

Address: Apt. 425 4346 Santiago Islands, Shariside, AK 38830-1874

Phone: +96313309894162

Job: Legacy Sales Designer

Hobby: Baseball, Wood carving, Candle making, Jigsaw puzzles, Lacemaking, Parkour, Drawing

Introduction: My name is Dean Jakubowski Ret, I am a enthusiastic, friendly, homely, handsome, zealous, brainy, elegant person who loves writing and wants to share my knowledge and understanding with you.