The following steps are the compilation and installation for Quagga on Ubuntu 12.04. Hopefully it is helpful for you.
- Install all dependency(package)
- sudo apt-get build-dep quagga
- Give the path for all configurations files and libraries used by quagga for starting. I use this one /opt/quagga .... and this is done by this comand:
- ./configure --enable-vtysh --prefix=/opt/quagga --localstatedir=/opt/quagga sysconfdir=/opt/quagga
- Create new folder:
- Add new user :
- Give the priviledge for the user quagga over the folder: /opt/quagga and for the folders and subfolders you give the privilegde for all rights : reading, changing and executing
- sudo chown quagga:quagga /opt/quagga
- sudo chmod 777 /opt/quagga
- Then you will be able to comiple Quagga:
Quagga configuration
--------------------
quagga version : 0.99.22
host operating system : linux-gnu
source code location : .
compiler : gcc
compiler flags : -Os -fno-omit-frame-pointer -g -std=gnu99 -Wall -Wsign-compare -Wpointer-arith -Wbad-function-cast -Wwrite-strings -Wmissing-prototypes -Wmissing-declarations -Wchar-subscripts -Wcast-qual
make : make
includes :
linker flags : -lcrypt -lrt -lcap -lm
state file directory : /opt/quagga
config file directory : /opt/quagga
example directory : /opt/quagga
user to run as : quagga
group to run as : quagga
group for vty sockets :
config file mask : 0600
log file mask : 0600
Now, let us try Quagga for some examples
- Zebra
- Copy sample to conf file:
- cd /opt/quagga
- cp zebra.conf.sample zebra.conf
- Start zebra daemon, you use this command
- sudo /opt/quagga/sbin/zebra &
- Check the daemon zebra:
- Get into the zebra, you use
- BGP
- Copy sample to conf file:
- cd /opt/quagga
- cp bgpd.conf.sample bgpd.conf
- Start bgpd:
- sudo /opt/quagga/sbin/bgpd &
- Check the daemon zebra:
- Get into the bgpd, you use
- vtysh
- cd /opt/quagga
- vi /opt/quagga/vtysh.conf
- sudo /opt/quagga/bin/vtysh
! Sample configuration file for vtysh.
!
!service integrated-vtysh-config
hostname quagga-router
username root nopassword
!
Stop Quagga Daemon ( for example: bgpd ):
- sudo kill `cat /opt/quagga/bgpd.pid`
Port Number:
zebra: 2601
ripd: 2602
ripng: 2603
ospfd: 2604
bgpd: 2605
ospf6d: 2606