Newer
Older
Preliminary Mininet Installation/Configuration Notes
(Disclaimer: this is an early alpha release; things may be broken.)
The easiest way to get Mininet running is to use one of our pre-built
virtual machine images from:
http://www.openflowswitch.org/foswiki/bin/view/OpenFlow/MininetGettingStarted
If you are Linux-savvy and wish to take on the challenge
of installing Mininet and its dependencies from scratch,
the requirements are described below.
These installation notes assume you understand how to do things
like compile kernels, apply patches, configure networks, write code,
etc.. If this is unfamiliar territory, we recommend using one of
1. Core Mininet installation
To install Mininet itself, with root privileges:
This places the mininet package in /usr/lib/python-2.5/site-packages/,
so that 'import mininet' will work, and installs the primary mn
script (mn) as well as its helper utility (mnexec.)
2. Linux Kernel requirements
Mininet requires a kernel built with network namespace support enabled,
If your kernel doesn't support it, you will need to build and install a
kernel that does! >= 2.6.33 works better, but may be harder to get
working, depending on your Linux distribution.
A script for building Debian packages for 2.6.33.1 is provided in
mininet/util/kbuild. You may wish to read it, as it applies patches
to enable 2.6.33.1 to build under debian-stable, and to enable the
tun driver to work correctly with Mininet.
Earlier kernels work (e.g. 2.6.29) work with CONFIG_NET_NS enabled and
no additional patches, but are much slower at removing veth interfaces,
resulting in much slower switch shutdown.
For scalable configurations, you might need to increase some of your
kernel limits. Sample params are in sysctl_addon, which can be appended to
/etc/sysctl.conf (and modified as necessary for your desired
configuration):
sudo su -c "cat sysctl_addon >> /etc/sysctl.conf"
To save the config change, run:
3. OpenFlow software and configuration requirements
Mininet requires either the reference OpenFlow switch implementation
(from openflowswitch.org) or Open vSwitch (openvswitch.org) to be
installed. "make test" requires the reference user and kernel
space implementations as well as Open vSwitch. Note the kernel
implementation is not currently included in OpenFlow 1.0.
To switch to the most recent OpenFlow 0.8.9 release branch (the most
git checkout -b release/0.8.9 remotes/origin/release/0.8.9
A patch to enable datapath.c to compile with recent kernels
is included in util/openflow-patches/datapath.patch
Mininet will automatically load and remove kernel module dependencies for
supported switch types, using modprobe and rmmod - but these modules must be
in a location where modprobe can find them (i.e. /lib/modules/...)
The reference OpenFlow controller (controller(8)) only supports 16
switches by default! If you wish to run a network with more than 16
switches, please recompile controller(8) with larger limits, or use a
different controller such as nox. A patch to controller(8) is included
4. Other software dependencies
To run the iperf test, you need to install iperf:
sudo aptitude/yum install iperf
We assume you already have ping installed. ;-)
To use xterm or sshd with Mininet, you need the following:
sudo aptitude/yum install sshd xterm screen
Some examples may have additional requirements - consult the specific
example file for details.
5. Other notes and recommendations
Mininet should be run either on a machine with
no other important processes, or on a virtual machine (recommended!)