Why Move from Static Routes to Dynamic Routing?
Manual network administration is a “nightmare” as systems scale. If you are managing 50-100 Virtual Machines, typing ip route add for every node is highly prone to errors. If an intermediate switch fails, all traffic will bottleneck unless you manually update the routes immediately.
Dynamic Routing solves this by allowing devices to exchange information automatically. Instead of fixed paths, protocols like OSPF or BGP help servers find new paths during failures. On Linux, FRRouting (FRR) is the current gold standard. Inherited from Quagga, it is much faster and more stable, with a command set very similar to Cisco IOS.
The Power of FRRouting in Modern Environments
FRR is more than just routing software. It is a Quagga fork optimized for cloud and containers, fully supporting BGP, OSPF, IS-IS, and even MPLS.
The multi-daemon architecture is FRR’s biggest advantage. Each protocol runs as an independent process. If OSPF fails, your BGP session remains unaffected, preventing full system downtime. The included vtysh tool provides a centralized management shell, allowing you to configure all protocols in one place.
Installing FRRouting on Ubuntu/Debian
To ensure stability and receive the latest security patches, you should use the official FRR repository instead of the default Ubuntu package.
# Install support packages and FRR
sudo apt update
sudo apt install -y frr frr-pythontools
After installation, routing protocols are disabled by default. You need to edit the /etc/frr/daemons file to enable the protocols you need.
sudo nano /etc/frr/daemons
Change the values from no to yes in the following lines:
ospfd=yes
bgpd=yes
Finally, restart the service to apply the changes:
sudo systemctl restart frr
Practical OSPF (Interior Gateway Protocol) Configuration
OSPF is the top choice for internal datacenters or corporate networks due to its ultra-fast convergence (usually under 1 second). Suppose you have 2 Linux nodes directly connected via the 10.0.0.0/30 IP range.
First, access the management shell:
sudo vtysh
Proceed with a configuration similar to Cisco devices:
conf t
router ospf
ospf router-id 1.1.1.1
network 10.0.0.0/30 area 0
network 192.168.1.0/24 area 0
exit
write memory
Pro-tip: When subnetting dozens of VLANs, I often use an IP Subnet Calculator to avoid IP conflicts. This tool quickly calculates network ranges and broadcasts for /30 or /31 subnets with high precision.
Deploying BGP for Leaf-Spine Architecture
BGP is no longer just for Internet ISPs. In large systems, BGP is used to connect different network regions (Autonomous Systems). Here is how to set up a basic eBGP session between AS 65001 and AS 65002.
conf t
router bgp 65001
bgp router-id 1.1.1.1
neighbor 10.0.0.2 remote-as 65002
!
address-family ipv4 unicast
network 192.168.10.0/24
exit-address-family
exit
write memory
Troubleshooting and Verification
Don’t celebrate just yet. You need to verify if the nodes “see” each other using the following status commands:
show ip route: Check the routing table. Routes marked with O are learned from OSPF, and B from BGP.show ip ospf neighbor: Ensure the state isFull. If it is stuck atInitorExStart, check your MTU or Firewall settings.show ip bgp summary: View the number of received prefixes.
If the BGP status shows Active or Idle, the connection is blocked or the AS parameters are incorrect. When a specific number appears, your system is truly operational.
3 Hard-Learned Lessons When Running FRR
1. Forgetting to Enable IP Forwarding: This is the most common mistake preventing traffic from passing through the server. You must allow Linux to forward packets using the following command:
echo "net.ipv4.ip_forward=1" | sudo tee -a /etc/sysctl.conf
sudo sysctl -p
2. Using Dummy Interfaces: Always set the Router-ID based on a Loopback (Dummy) interface. Physical interfaces can be unplugged, but virtual interfaces always exist, preventing routing sessions from resetting unnecessarily.
3. Controlling Prefix Lists: Never trust your neighbors blindly. Use prefix-list to filter unusual IP ranges, preventing the routing table from being poisoned by unwanted routes.
Conclusion
FRRouting turns a low-cost Linux server into a professional router capable of handling millions of routes. Mastering OSPF and BGP on FRR allows you to control your network infrastructure without relying on expensive hardware. Start by building a small lab with 3 virtual machines to witness the true power of Dynamic Routing.

