TTR Networks

Intermediate · Route reflectors on VyOS · section 6 of 6

Build the lab yourself

✓ Lab-tested 18 October 2026 on VyOS 2026.10.16-0024-rolling, FRR 10.2.1

Two VyOS VMs and three FRR containers on one Docker network. Put ./vyos (from the Packets That Never Come Back lesson's get-vyos.sh) and FRR's daemons file (bgpd=yes) next to these files, run docker compose up -d --build, and apply the reflector stages in the order shown. c2 and c3 have the same configuration as c1, with their own address (and c3 its own prefix, 192.0.2.0/24).

lab-compose.yaml
# Needs ./vyos (from the tcpdump-and-vyos lesson's get-vyos.sh) and ./daemons (copy /etc/frr/daemons out of the FRR image, set bgpd=yes).
# Then: docker compose up -d --build, and apply the RR stages on the VyOS consoles.
name: vyos-rr-lab
x-frr: &frr
  image: quay.io/frrouting/frr:10.2.1
  privileged: true
x-vyos: &vyos
  build:
    context: .
    dockerfile_inline: |
      FROM debian:bookworm-slim
      RUN apt-get update && apt-get install -y --no-install-recommends qemu-system-x86 iproute2 socat
      COPY start-vyos.sh /usr/local/bin/start-vyos.sh
      CMD ["/usr/local/bin/start-vyos.sh"]
  cap_add: [NET_ADMIN]
  devices: ["/dev/net/tun:/dev/net/tun"]
  volumes: ["./vyos:/vyos:ro"]
services:
  rr1:
    <<: *vyos
    environment: { VYOS_MEM: "1536", VYOS_SMP: "1", VM_ID: "01" }
    networks: { core: { interface_name: eth0 } }
  rr2:
    <<: *vyos
    environment: { VYOS_MEM: "1536", VYOS_SMP: "1", VM_ID: "02" }
    networks: { core: { interface_name: eth0 } }
  c1:
    <<: *frr
    volumes: ["./daemons:/etc/frr/daemons:ro", "./c1.conf:/etc/frr/frr.conf"]
    networks: { core: { interface_name: eth0 } }
  c2:
    <<: *frr
    volumes: ["./daemons:/etc/frr/daemons:ro", "./c2.conf:/etc/frr/frr.conf"]
    networks: { core: { interface_name: eth0 } }
  c3:
    <<: *frr
    volumes: ["./daemons:/etc/frr/daemons:ro", "./c3.conf:/etc/frr/frr.conf"]
    networks: { core: { interface_name: eth0 } }
networks:
  core: { enable_ipv4: false, enable_ipv6: true, ipam: { config: [{ subnet: "fd00:60::/64" }] } }
  • Lines 19–26: The two reflectors.
  • Lines 27–38: The three clients.

Where next

  • Edge and core: building out a VyOS networkPrerequisite · Intermediate · 60 min

    Split one BGP router into edge routers that face the outside world and a core that carries traffic inside: loopbacks, OSPF for infrastructure, iBGP between loopbacks, next-hop-self, and what happens when a link fails. Built and broken on three real VyOS routers.

  • BGP FundamentalsAlso covers BGP, iBGP, route reflector · Intermediate · 75 min

    How the Border Gateway Protocol glues the internet together: autonomous systems, sessions, path attributes, best-path selection, iBGP scaling and a hands-on eBGP lab with real FRR configuration.

  • BGP on loopbacks vs interface addressesAlso covers BGP, iBGP · Intermediate · 45 min

    Why BGP sessions between loopbacks survive link failures and use parallel links, and what they need to work: an IGP or static routes, update-source, the eBGP connected check, and BFD. Every failure is reproduced on two real VyOS routers.

  • IPv4 over an IPv6-only core (RFC 8950)Also covers BGP · Intermediate · 40 min

    Carry IPv4 routes over IPv6 BGP sessions with IPv6 next hops, so core routers need no IPv4 addresses at all. Built on VyOS: the missing router ID, what breaks without the extended next hop capability, native IPv4 on the wire, and why traceroute shows 192.0.0.8.