Labs / Internetwork / RIP & OSPF

Lab 2 of 3 · RIP & OSPF

OSPF: routers that find their own routes

Let routers map the network themselves and reroute when one fails.

Open this lab Pro 5 steps

The idea

officeRouter, coreRouter and dataCenterRouter run OSPF: the routers share a map of every link, each computes the cheapest path itself, and a laptop in the office keeps reaching the data center's web server when coreRouter fails.

A cost counts on the way out
A cost counts on the way out
The route before and after coreRouter fails
The route before and after coreRouter fails

Steps

  1. Hello, is anyone there?

    Each OSPF router says Hello on its links every second. Listen on coreRouter, then list officeRouter's neighbours. Routers share maps only with neighbours they hear, so finding them comes first.

    coreRouter:~# timeout 3 tcpdump -nni any -v proto ospf
    officeRouter:~# vtysh
  2. One map, shared by all

    Each router describes its own links and floods that to everyone. Read officeRouter's map, then dataCenterRouter's. If every router holds the same map, they all agree on the network, and their routes cannot contradict each other.

    officeRouter:~# vtysh
    dataCenterRouter:~# vtysh -c 'show ip ospf database'

Pro

3 more steps in the app

  1. The shortest path wins
  2. Change a cost, change the path
  3. A router fails, the network heals
Get Pro

Learn it on real machines.

Every lab is a small network of real Linux machines in your browser. Start with a free account: Google or email, no card.

Open this lab