wiki:Proto/cModules/a0ClickRouter/b0Installation
close Warning: Can't synchronize with repository "(default)" ("(default)" is not readable or not a Git repository.). Look in the Trac log for more information.

Installation

Debian Package Installation

Make sure you have appropriate package repository configured.

Configure Apt Repository

To begin we'll need to add the Orbit apt repository to the list of sources that our console will pull packages from. This is done by running the following two commands.

Note: It is assumed that you have root access and can run these commands as root if needed

The first installs the orbit repositories gpg-key into the consoles key-ring.

wget -qO - http://packages.orbit-lab.org/downloads/orbitapt.gpg.key | sudo apt-key add -

Next we download the source list for the repository.

wget -qO /etc/apt/sources.list.d/orbit.list http://packages.orbit-lab.org/downloads/orbit-precise.list

Once we have these changes in place, we need to update the repository list via

apt-get update

Configure OML apt Repository

OML libraries are required to proceed with the installation. They are installed automatically once the repositories list have been added correctly.

Note: It is assumed that you have root access and can run these commands as root if needed

First, append the following line to /etc/apt/sources.list, choosing the one appropriate for your Ubuntu version:

#Ubuntu 10.04
deb http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_10.04/ ./
    
#Ubuntu 12.04
deb http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_12.04/ ./

You also need to add the repository key before the actual download (requires curl or similar):

#Ubuntu 10.04
wget -qO- http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_10.04/Release.key | sudo apt-key add -
        
#Ubuntu 12.04
wget -qO- http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_12.04/Release.key | sudo apt-key add -

Once we have these changes in place, we need to update the repository list via:

sudo apt-get update

The click modular router with MF extensions is installed with:

sudo apt-get install mfclick

The will install the binaries in /usr/local/bin/{mf_click,mf_click_mon}.

Compiling From Source

The following instructions are for Ubuntu distributions and in particular have been tested with 10.04 and 12.04 (with the differences noted where applicable). Since the implementation runs in user-level Click, these steps may work with later distributions also.

1. Required Packages

sudo apt-get update
sudo apt-get -y install git-core libpcap-dev openssl libssl-dev

2. Download Click Modular Router Sources

MobilityFirst router elements are currently implemented as user-level elements, and should pose no compatibility issues with specific Linux kernel versions. The latest sources Click can be obtained from Click Project website or from GitHub:

git clone git://github.com/kohler/click.git click

While the latest Click sources presented no issues as of this writing, a safe option is to check out version 2.0.1 from the repository cloned above:

cd click
git checkout v2.0.1

Set and export the path of Click sources root folder ('click') to env. variable CLICK_SRC.

3. Download MobilityFirst Sources

Git: The development versions of the prototype components can be checked out from the MobilityFirst git repository host on orbit-lab:

git clone ssh://username@external2.orbit-lab.org/common/git/mf

Note: cloning the git repository requires setting your ssh agent to use your orbit-lab key pair.

Set and export path of top-level folder to an env. variable 'MF_SRC'

4. Install Optional Packages

4.1. Install OML Client Libraries

This is required for optionally running OML-based Click Monitor for logging traffic and resource statistics to a backend OML database. The libraries can be obtained and installed from the OML repository at Opensuse.org using the following steps. Refer to installation instructions at the OML project website site for additional details and troubleshooting.

First, append the following line to /etc/apt/sources.list, choosing the one appropriate for your Ubuntu version:

#Ubuntu 10.04
deb http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_10.04/ ./
    
#Ubuntu 12.04
deb http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_12.04/ ./

You also need to add the repository key before the actual download (requires curl or similar):

#Ubuntu 10.04
curl http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_10.04/Release.key | sudo apt-key add -
        
#Ubuntu 12.04
curl http://download.opensuse.org/repositories/home:/cdwertmann:/oml/xUbuntu_12.04/Release.key | sudo apt-key add -

Now download and install the OML client packages:

sudo apt-get update
sudo apt-get -y install liboml2 liboml2-dev

4.2. Install JDK/JRE and Maven Build Tools (required for GNRS)

Java JRE 1.6 or later is required to run the GNRS server and can be installed as:

#Ubuntu 10.04
sudo apt-get install openjdk-6-jre

#Ubuntu 12.04
sudo apt-get install openjdk-7-jre

The above is sufficient if the pre-built server jar is available. If building GNRS from the sources then the full JDK and Maven build tools are required:

#Ubuntu 10.04
sudo apt-get install openjdk-6-jdk maven2

#Ubuntu 12.04
sudo apt-get install openjdk-7-jdk maven

5. Compiling Click with MobilityFirst Elements

Copy sources of MobilityFirst elements and common header files into designated folder under Click sources for compilation:

cd $MF_SRC/router/click/elements
cp gstar/* gnrs/* test/* utils/* $CLICK_SRC/elements/local/
cp $MF_SRC/common/include/* $CLICK_SRC/elements/local

Now configure and compile Click with flags for user-level operation, to include locally added elements, and to support multi-threading:

cd $CLICK_SRC
./configure --disable-linuxmodule --enable-local --enable-user-multithread 
make elemlist
make
sudo make install

The last command should install user-level Click binary under /usr/local/bin

6. Building GNRS Server (optional)

For running MobilityFirst routers with the GNRS instances, use the stable version of the Java-based GNRS server contained within the repository under $MF_SRC/gnrs/jserver. You can find instructions on the main wiki to install and configure the GNRS service.

7. Compiling Click Monitor (optional)

The OML-based monitor is an independent binary that interacts with router through Click's control interface to report traffic and resource statistics to a OML backend data repository. It is an optional component and can be built as below:

cd $MF_SRC/router/click/monitor
make
make install

The last command will install the binary as /usr/local/bin/mf_click_mon.

Last modified 4 years ago Last modified on Sep 14, 2017, 8:04:03 PM
Note: See TracWiki for help on using the wiki.