Sign inSign up

arbiza/frr

By arbiza

Updated about 8 years ago

FRRouting (FRR) IP routing protocol suite built to run on Docker.

Image
0

487

arbiza/frr repository overview

From the FRR's page:

"FRRouting (FRR) is an IP routing protocol suite for Linux and Unix platforms which includes protocol daemons for BGP, IS-IS, LDP, OSPF, PIM, and RIP."

FRR has several releases; this Docker image runs RPKI (Resource Public Key Infrastructure) enabled versions - tags indicate the FRR version built.

FRR runs many protocol daemons. See the section Environment variables below to limit the daemons will run.

I built this image for a GNS3-based network laboratory for a BGP course.

Persisting data

"write memory" command saves configuration changes in the FRR directory (/etc/frr) mounted as a Docker volume.

Usage

Running

Interactive mode:

Running in interactive mode (-it) you will get in the vtysh shell:

docker run --privileged -ti arbiza/frr

Background mode:

docker run --privileged -d arbiza/frr

When running in the background (daemon) you may connect to vtysh or to each protocol daemon individually. Don't use the Docker attach to connect or you'll get into a loop.

The command below connects to the container's vtysh:

docker exec -ti container_name_or_id vtysh

In order to connect to a specific daemon, get the container's IP through docker inspect container-name-or-id command then use it in the command below:

telnet container's_IP daemon's_port

Option for daemon's port are:

  • zebra: 2601
  • RIPd: 2602
  • RIPngd: 2603
  • OSPFd: 2604
  • BGPd: 2605
  • OSPF6d: 2606
  • ospf: 2607
  • ISISd: 2608
  • BABELd: 2609
  • nhrpd: 2610
  • PIMd: 2611
  • LDPd: 2612
  • EIGRPd: 2613
  • bfdd: 2617

The password is frr

Environment variables

DAEMONS: Set this variable listing (space separated) the daemons you want the FRR run. Options are:

  • zebra
  • ripd
  • ldpd
  • sharpd
  • bgpd
  • ripngd
  • nhrpd
  • pbrd
  • ospfd
  • isisd
  • eigrpd
  • ospf6d
  • pimd
  • babeld

By default, FRR runs all the daemons above.

In the example below, FRR runs zebra, OSPF and BGP daemons only:

docker run --privileged -ti -e DAEMONS='zebra ospfd bgpd' arbiza/frr

uRPF - Reverse Path Forwarding

FRR doesn't have commands to change RPF configuration. By default all RPF values are set to 0, but if you run this image in GNS3 it will set all values to 1.

As this image is based on Debian Linux, you can use the environment variables to change kernel's uRPF parameters:

  • RPF_all: changes the net.ipv4.conf.all.rp_filter parameter to enabled (1) or disabled (0). Linux performs an OR operation for rp_filter, it means that when the all parameter is 1, it will run uRPF on all interfaces regardless its individual values.
  • RPF_set_on_iface: sets the net.ipv4.conf..rp_filter parameter to 1 enabling uRPF on that interface regardless what is set for the all parameter.
  • RPF_unset_on_iface: set net.ipv4.conf..rp_filter to 0 disabling uRPF on that interface - the all parameter must be 0 for this to work.

The following example enables uRPF on interfaces eth2 and eth3 only:

docker run --privileged -d -e RPF_all='0' -e RPF_set_on_iface='eth2 eth3' arbiza/frr

The following example disables uRPF on interfaces eth2 and eth3:

docker run --privileged -d -e RPF_all='0' -e RPF_unset_on_iface='eth2 eth3' -e RPF_set_on_iface='eth0 eth1' arbiza/frr

GNS3

Importing:

Import to GNS3 by using the menu File > Import appliance and selecting the file arbiza-frr.gns3a.

Known issues:

Problems may occur when you reopen a project that uses this image. GNS3 creates a volume for each container using this image, but after closing the project and reopening it something goes wrong. Every time you make changes in the volume by issuing write memory command, export the topology as a portable project. No problems have occurred using portable projects.

Repository

All the files to build this image are available on a Bitbucket Repository.

Tag summary

Content type

Image

Digest

Size

99.1 MB

Last updated

about 8 years ago

docker pull arbiza/frr