05 Dec 2015

A Network in a Laptop: Rapid Prototyping for Software Defined Networks

HotNets'10, cited over 500+ 2015/12/05 06:22:47

ABSTRACT Mininet is a system for rapidly prototyping large networks on the constrained resources of a single laptop. The lightweight approach of using OS-level virtualization features, including processes and network namespaces, allows it to scale to hundreds of nodes. Experiences with our initial implementation suggest that the ability to run, poke, and debug in real time represents a qualitative change in workflow. We share supporting case studies culled from over 100 users, at 18 institutions, who have developed Software-Defined Networks (SDN). Ultimately, we think the greatest value of Mininet will be supporting collaborative network research, by enabling self-contained SDN prototypes which anyone with a PC can download, run, evaluate, explore, tweak, and build upon.

Share-able: self-contained prototypes should be easily shared with collaborators, who can then run and modify our experiments.

There are efforts underway to build programmable testbeds (e.g. Emulab [9], VINI [1], GENI [6], FIRE [5]) supporting realistic user traffic, at scale, and with interactive behavior. Our approach is complementary to these systems. We seek a local environment that allows us to quickly implement a functionally correct, well-understood prototype, then directly move it onto shared global infrastructure.

3. MININET WORKFLOW

3.3 Customizing a Network

Mininet exports a Python API to create custom experiments, topologies, and node types… A few lines of Python are sufficient to define … that creates a network, executes commands on multiple nodes, and displays the results. An example script:

from mininet.net import Mininet
from mininet.topolib import TreeTopo 
tree4 = TreeTopo(depth=2,fanout=2)
net = Mininet(topo=tree4)
net.start() 
h1, h4 = net.hosts[0], net.hosts[3]
print h1.cmd(’ping -c1 %s’ % h4.IP())
net.stop()

creates a small network (4 hosts, 3 switches) and pings one host from another, in about 4 seconds.

3.4 Sharing a Network

Mininet is distributed as a VM with all dependencies pre-installed, runnable on common virtual machine monitors such as VMware, Xen and VirtualBox. The virtual machine provides a convenient container for distribution;

4. SCALABILITY

Lightweight virtualization is the key to scaling to hundreds of nodes while preserving interactive performance.

5. LIMITATIONS

The most significant limitation of Mininet today is a lack of performance fidelity, especially at high loads.

CPU resources are multiplexed in time by the default Linux scheduler, which provides no guarantee that a host that is ready to send a packet will be scheduled promptly, or that all switches will forward at the same rate. In addition, software forwarding may not match hardware. O(n) linear lookup for software tables cannot approach the O(1) lookup of a hardware-accelerated TCAM in a vendor switch, causing the packet forwarding rate to drop for large wildcard table sizes.

To enforce bandwidth limits and quality of service on a link, the linux traffic control program (tc) may be used. Linux CPU containers and scheduler priorities offer additional options for improving fairness.

Mininet’s partial virtualization approach also limits what it can do. It cannot handle different OS kernels simultaneously. All hosts share the same filesystem, although this can be changed by using chroot. Hosts cannot be migrated live like VMs. We feel that these losses are a reasonable tradeoff for the ability to try ideas at greater scale.

6. CASE STUDIES

Optimization
The OpenFlow controller NOX builds a topology database by sending periodic LLDP packet broadcasts out each switch port [8].

8. DISCUSSION

Wrapping a Mininet-based design in a VM creates a “network appliance” that can be distributed over the internet.