Use Sophia to knock out your gen-ed requirements quickly and affordably. Learn more
×

Static & Dynamic Routing

Author: Sophia
what's covered
In this lesson, you will learn static and dynamic routing.

Specifically, this lesson will cover the following:

Table of Contents

1. Static and Dynamic Routing

think about it
How does a router send packets to remote networks when the only way it can send them is by looking at the routing table to find out how to get to the remote networks?

And what happens when a router receives a packet for a network that isn’t listed in the routing table?

It doesn’t send a broadcast looking for the remote network—the router just discards the packet.

There are several ways to configure the routing tables to include all the networks so that packets are forwarded. Understand that what’s best for one network isn’t necessarily what’s best for another. Knowing about and being able to recognize the different types of routing will really help you come up with the best solution for your specific environment and business requirements.

Looking at the diagram below, you can see that we can configure a router with either static or dynamic routing. If we choose static routing, then we have to go to each router and type in each network and the path that IP will use to send packets.

hint
Static routing does not scale well in large networks, but dynamic routing does because network routes are automatically added to the routing table via the routing protocol.

Static and dynamic routing.

Dynamic routing protocols break into many different categories or types of protocols, as shown in the diagram below. The first split in the dynamic protocol branch is the division of interior gateway protocols (IGPs) and exterior gateway protocols (EGPs). We are going to talk about each protocol and category but for now the difference between IGP and EGP is the interior or exterior routing of an autonomous system (AS).

Dynamic Routing Options

An autonomous system (AS) is a collection of networks or subnets that are in the same administrative domain. This is another way of saying an administrative domain is within your company’s network, and you control or administer all the subnets that are within it. You control and set the policy for what happens in the network or autonomous system. An IGP operates and routes within an AS and an EGP works outside or between more than one AS.

The most popular protocol for an EGP is Border Gateway Protocol (BGP), which is typically used by ISPs or really large corporations. As an administrator of a small to medium network, you’ll probably never use BGP. BGP will be discussed later in the course.

Now that we have that out of the way, let’s talk about the functions of dynamic routing protocols. Manageability is a benefit of dynamic routing because of the amount of time and energy we save configuring routers. We won’t have to go to every single router and define for it, with a static route, what and where every destination network is. The protocols will take care of most of the updating and sending information to each other.

That is the end of the EGP branch of the tree, but the IGP branch continues to split out as we go down further. Looking at the diagram below, with the IGP split, you can see that there are two primary categories: distance-vector (DV) and link-state (LS) routing protocols.

DV and LS Routing Protocols

did you know
You will learn about these types of protocols later in the course. But in the distant vector category, for example, we have Routing Information Protocol (RIP), Interior Gateway Routing Protocol (IGRP), and Enhanced Interior Gateway Routing Protocol (EIGRP). Under the link-state category are the nonproprietary Open Shortest Path First (OSPF) and Intermediate System-to-Intermediate System (IS-IS) that were designed to work in larger internetworks.

Now, in the diagram below, you can see that there is a third category: the hybrid protocol category.

Hybrid Routing

terms to know
Interior Gateway Protocols (IGPs)
Protocols for routing within an autonomous system.
Exterior Gateway Protocols (EGPs)
Protocols for routing between different autonomous systems.
Autonomous System
A collection of networks or subnets that are in the same administrative domain.
Border Gateway Protocol (BGP)
Border Gateway Protocol (BGP) is a standardized exterior gateway protocol designed to exchange routing and reachability information among autonomous systems (AS) on the internet.
Distance-Vector (DV) Protocols
A class of routing protocol based on sending global state between neighboring nodes.
Link-State (LS) Protocols
A class of routing protocols used in packet switching networks for computer communications.
Enhanced Interior Gateway Routing Protocol (EIGRP)
An advanced distance-vector routing protocol that is used on a computer network for automating routing decisions and configuration.
Open Shortest Path First (OSPF)
A link-state routing algorithm that is used to calculate routes based on the number of routers, transmission speed, delays and route cost.
Intermediate System-to-Intermediate System (IS-IS)
A routing protocol designed to move information efficiently within a computer network, a group of physically connected computers or similar devices.


2. Administrative Distances

The administrative distance (AD) is used to rate the trustworthiness of routing information received on one router from its neighboring router (and has nothing to do with the physical distance between devices). An AD is represented as an integer from 0 to 255, where 0 equals the most trusted route and 255 the least. A value of 255 essentially means “No traffic is allowed to be passed via this route.”

If a router receives two different updates listing the same remote network, the first thing the router checks is the AD. If one of the advertised routes has a lower AD than the other, the route with the lower AD is the one that will get placed in the routing table.

If both advertised routes to the same network have the same AD, then routing protocol metrics like hop count or the amount of bandwidth on the lines will be used to find the best path to the remote network. And as it was with the AD, the advertised route with the lowest metric will be placed in the routing table. But if both advertised routes have the same AD as well as the same metrics, then the routing protocol will load-balance to the remote network. To perform load balancing, a router will send packets down each link to test for the best one.

EXAMPLE

The following table shows the default ADs that a router uses to decide which route to take to a remote network.

Route Source Default AD
Connected interface 0
Static route 1
External BGP 20
Internal EIGRP 90
IGRP 100
OSPF 110
IS-IS 115
RIP 120
External EIGRP 170
Internal BGP 200
Unknown 255

If a network is directly connected, the router will always use the interface connected to that network. Also good to know is that if you configure a static route, the router will believe that route to be the preferred one over any other routes it learns about dynamically. You can change the ADs of static routes, but by default, they have an AD of 1. That’s only one place above zero, so you can see why a static route’s default AD will always be considered the best by the router.

This means that if you have a static route, a RIP-advertised route, and an EIGRP-advertised route listing the same network, then by default, the router will always use the static route unless you change the AD of the static route.

term to know
Administrative distance (AD)
A number of arbitrary unit assigned to dynamic routes, static routes, and directly connected routes.


3. Classes of Routing Protocols

The three classes of routing. They are Distance Vector, Link State, and Hybrid.

3a. Distance Vector

The distance-vector protocols find the best path to a remote network by judging distance. Each time a packet goes through a router, it equals something we call a hop, and the route with the fewest hops to the destination network will be chosen as the best path to it.

key concept
The vector indicates the direction to the remote network. RIP, RIPv2, and Interior Gateway Routing Protocol (IGRP) are distance-vector routing protocols.

These protocols send the entire routing table to all directly connected neighbors.

3b. Link State

Using link-state protocols, also called shortest path first protocols, the routers each create three separate tables. One of these tables keeps track of directly attached neighbors, one determines the topology of the entire internetwork, and one is used as the actual routing table.

key concept
Link-state routers know more about the internetwork than any distance-vector routing protocol. OSPF and IS-IS are IP routing protocols that are completely link state.

Link-state protocols send updates containing the state of their own links to all other routers on the network.

3c. Hybrid

A hybrid protocol uses aspects of both distance vector and link state. EIGRP and BGP are hybrid routing protocols. BGP has the capability to work as an EGP, and to be used in supersized internetworks internally. When deployed in this way, it’s called internal BGP, or iBGP, but understand that it’s still most commonly utilized as an EGP.

think about it
There is no one set way of configuring routing protocols for use in every situation because this really needs to be done on a case-by-case basis. Even though all of this might seem a little intimidating, if you understand how each of the different routing protocols works, you’ll be capable of making good, solid decisions that will truly meet the individual needs of any business.

summary
In this lesson, you learned about static and dynamic routing, administrative distances, and classes of routing protocols, including distance-vector protocols, link-state protocols, and hybrid protocols.

Source: This content and supplemental material has been adapted from CompTIA Network+ Study Guide: Exam N10-007, 4th Edition. Source Lammle: CompTIA Network+ Study Guide: Exam N10-007, 4th Edition - Instructor Companion Site (wiley.com)

Terms to Know
Administrative Distance (AD)

A number of arbitrary unit assigned to dynamic routes, static routes, and directly connected routes.

Autonomous System

A collection of networks or subnets that are in the same administrative domain.

Border Gateway Protocol (BGP)

Border Gateway Protocol (BGP) is a standardized exterior gateway protocol designed to exchange routing and reachability information among autonomous systems (AS) on the internet.

Distance-Vector (DV) Protocols

A class of routing protocol based on sending global state between neighboring nodes.

Enhanced Interior Gateway Routing Protocol (EIGRP)

An advanced distance-vector routing protocol that is used on a computer network for automating routing decisions and configuration.

Exterior Gateway Protocols (EGPs)

Protocols for routing between different autonomous systems.

Interior Gateway Protocols (IGPs)

Protocols for routing within an autonomous system.

Intermediate System-to-Intermediate System (IS-IS)

A routing protocol designed to move information efficiently within a computer network; a group of physically connected computers or similar devices.

Link-State (LS) Protocols

A class of routing protocols used in packet switching networks for computer communications.

Open Shortest Path First (OSPF)

A link-state routing algorithm that is used to calculate routes based on the number of routers, transmission speed, delays, and route cost.