Nicholas Morrison - Networking Specialist

S1E5-6-7 - Static vs Dynamic routing


Topology: five-routers-five-pcs

(You may notice that since creating this topology, there are now more than five routers and more than five pcs. Please do your best to ignore this naming discrepancy.)

Topology: five-routers-five-pcs

Catch-up cheat-sheet (1/4)

Connect to the lab server:

local$ ssh-keygen -R
local$ ssh [email protected]
Password: (see discord)

Connect to your router:

lab@netlab$ list-routers                           <- list all lab routers
lab@netlab$ list-pcs                               <- list all lab PCs
lab@netlab$ docker exec -it clab-clintro-r7 Cli    <- connect to your router

Catch-up cheat-sheet (2/4)

Configure your router interfaces:

r7>enable                    <- enable mode
r7#configure                 <- configuration mode
r7(config)#interface ethernet 1
r7(config-if-eth1)#description Link to Switch
r7(config-if-eth1)#no switchport
r7(config-if-eth1)#ip address
r7(config-if-eth1)#interface ethernet 2
r7(config-if-eth2)#description Link to PC
r7(config-if-eth2)#no switchport
r7(config-if-eth2)#ip address

Catch-up cheat-sheet (3/4)

Enable routing, and configure your static routes:

r7(config)#ip routing
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7(config)#ip route
r7#wr                     <- save your configuration

Catch-up cheat-sheet (4/4)

Verify your configuration:

r7#ping          <- can you ping your PC?
r7#ping             <- can you ping your neighbours?
r7#ping             <- try a bunch
r7#ping             <- to make sure
r7#ping          <- can you ping your neighbours' PC?
r7#ping          <- try some more
r7#ping          <- then you're sure
r7#show run                  <- take a look at your configuration
r7#show run | include route  <- filter for specific text
r7#show ip route             <- look at your routing table

Static Routes

“For packets with a destination in this network, send them to this router.”

ip route
                 ^ destination     ^ router
  • Receive a packet (dst:
  • Is there a matching entry in the routing table? (show ip route or show ip route
  • Yes! via
  • Forward that packet to

Dynamic Routing

  • Programming routes manually (configure, ip route x.x.x.x/xx x.x.x.x) takes time and is error-prone.
  • Static routes must be manually updated if the network topology changes.
  • A routing protocol can take the pain away (and potentially introduce a brand new kind of pain.)
  • We will configure RIPv2 - the Routing Information Protocol

About RIP

  • RIP is the Routing Information Protocol
  • RFC 1058, from 1988.
  • Distance Vector: counts “hops” to decide which path is best
  • Aside from Distance Vector protocols, we also have Link State Vector and Path Vector protocols.

Configuring RIP

Remove all of your static routes. You can use a text editor if you want to.

no ip route
no ip route
no ip route
! etc

Add the following configuration:

router rip
  no shutdown             <- enable RIP (it's shutdown by default)
  network     <- run RIP on any interface in this range

Verify your RIP configuration

Look at the config:

rX#show run | section router rip

Check your routing table. Do you see any RIP routes?

rX#show ip route
rX#show ip route rip

Check the RIP process itself:

rX#show ip rip database
rX#show ip rip neighbors

Next session: a presentation about Routing Protocols