Labs / Internetwork / BGP: the internet's routing

Lab 1 of 2 · BGP: the internet's routing

BGP: how the networks of the internet find each other

Join autonomous systems with BGP, steer traffic by prepending and survive a cut.

Open this lab Pro 5 steps

The idea

With BGP, homeIsp, transitIsp and contentProvider, networks run by different organisations, tell each other which addresses they reach and through whom. A laptop at homeIsp reaches contentProvider's web server by the shortest list of networks.

Each network adds its number
Each network adds its number
Prepending steers one direction
Prepending steers one direction

Steps

  1. Sessions over TCP

    homeIsp, a home ISP, swaps routes with two other organisations: transitIsp and contentProvider. In vtysh, FRR's shell, list its BGP sessions, then the connections under them.

    homeIsp:~# vtysh
    homeIsp:~# ss -tn state established '( sport = :179 or dport = :179 )'
  2. Who can reach what: the AS path

    Read homeIsp's BGP table: every network it heard of, and through whom. Then read transitIsp's, in the middle. This table is how BGP chooses a way and avoids loops, so reading it is the core skill.

    homeIsp:~# vtysh
    transitIsp:~# vtysh

Pro

3 more steps in the app

  1. The shortest AS path wins
  2. Steering traffic from the other side: prepending
  3. A link breaks: the hold timer
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