The main objective of [RARE / FreeRouter 101] series is to help you getting started with FreeRouter from scratch without any prior knowledge.
Requirement
- Basic Linux/Unix knowledge
- Basic networking knowledge
Overview
freeRouter is a free, open source router control plane software. For nostalgic and old networkers (like me), freeRouter is able to handle HDLC, X25, frame-relay, ATM encapsulation.
...
- no global routing table: every routed interface must be in a virtual routing table
- positive side effect: there are no vrf-awareness questions
Article objective
This article is meant to simply deploy 2 instances of freeRouter on the same fresh linux installed linux box.
...
But let's get our "hand dirty" and follow the simple manual installation.
Diagram
Cookbook #001
Expand |
---|
title | Install your favorite operating system |
---|
|
In our example we will use a genuine debian stable image (buster) installed as a VirtualBox VM.
|
Expand |
---|
title | Install Get your favorite operating system up to date |
---|
|
- Start & connect your VM as
Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
| apt-get update
apt-get upgrade |
- Install operating system default java package
Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
| apt-get install default-jre-headless |
|
Expand |
---|
title | Install operating system java package |
---|
|
...
|
In this example, we won't recompile freeRouter so installing headless java runtime is enough. This set up is recommended for production environment in order to ensure minimal software footprint Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
| apt-get install default-jre-headless --no-install-recommends |
|
Expand |
---|
title | Create freeRouter environment |
---|
|
Let's create the following structure, even if some folder are empty for now: Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
| mkdir -p ~/freeRouter/bin ~/freeRouter/lib ~/freeRouter/etc ~/freeRouter/log
cd ~/freeRouter/lib
wget http://freerouter.nop.hu/rtr.jar |
so you have have the following environment: Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
| ╭─[11:11:54]floui@debian ~
╰─➤ tree freeRouter
freeRouter
├── bin
├── etc
├── lib
└── log |
|
Expand |
---|
title | Create freeRouter configuration files |
---|
|
FreeRouter uses 2 configuration files in order to run: Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
title | freeRouter hardware file: ${ROUTER_NAME}-hw.txt |
---|
| int eth1 eth 0000.1111.0001 127.0.0.1 26011 127.0.0.1 26021 |
Code Block |
---|
language | bash |
---|
theme | Midnight |
---|
title | freeRouter software configuration file: ${ROUTER_NAME}-sw.txt |
---|
| hostname r1
int eth1
desc r2 e1
exit
int eth2
desc r3 e2
exit
|
|