Statistics
| Branch: | Tag: | Revision:

mininet / examples @ 4219b229

Name Size Revision Age Author Comment
  test e0bf8ece almost 6 years Bob Lantz Minor code cleanup
README.md 3.84 KB d334c1cc about 6 years Brian O'Connor adding test for vlanhost.py and adding vlantopo...
__init__.py 48 Bytes 045ef7b8 about 7 years Bob Lantz Add docstring to satisfy pylint
baresshd.py 1.05 KB 7c5d2771 about 6 years cody burkard wait for sshd to start in example
bind.py 2.26 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
cluster.py 30.5 KB 34933ef7 almost 6 years cody burkard use ControlPersist ssh option to create a Contr...
clusterSanity.py 503 Bytes e0bf8ece almost 6 years Bob Lantz Minor code cleanup
clustercli.py 3.48 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
clusterdemo.py 640 Bytes dd876e69 almost 6 years Bob Lantz DemoCLI -> ClusterCLI
consoles.py 15.2 KB 9bfc7c77 about 7 years Bob Lantz Satisfy pylint
controllers.py 1.03 KB 2e7d0d49 about 7 years Brian O'Connor fixed indent issue with examples/controllers.py
controllers2.py 1.57 KB 0fe73a67 over 6 years Bob Lantz build=False is unnecessary if topo=None, which ...
controlnet.py 4.66 KB cfb6bf95 about 7 years Brian O'Connor adding commandline args to UserSwitch in contro...
cpu.py 2.03 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
emptynet.py 960 Bytes ecddbcf2 about 7 years Brian O'Connor updated emptynet to use addLink
hwintf.py 1.5 KB 220376b6 about 7 years Brian O'Connor hwintf.py: allow intf to be specified in cmd line
intfoptions.py 1.3 KB 37bdf14b almost 6 years Bob Lantz Rename examples.{intfOptions,multiLink} -> {int...
limit.py 1.93 KB 58324bdc about 6 years cody burkard check if RT_GROUP_SCHED is enabled in kernel
linearbandwidth.py 3.9 KB 4a304688 almost 6 years Bob Lantz Select TCP Reno and run iperf for a longer time...
linuxrouter.py 2.19 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
miniedit.py 152 KB 3d44bcdc almost 6 years Bob Lantz MiniNet -> Mininet
mobility.py 4.1 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
multilink.py 766 Bytes e0bf8ece almost 6 years Bob Lantz Minor code cleanup
multiping.py 2.18 KB 891d8071 about 7 years Brian O'Connor fixed multiping example
multipoll.py 2.41 KB edf60032 almost 8 years Brandon Heller pep8: fix E128 continuation line under-indented...
multitest.py 1.02 KB b605cf74 about 7 years Brian O'Connor style in multitest
nat.py 3.77 KB 824afb84 almost 7 years Rémy Léone fixup: useless_parenthesis
natnet.py 1.92 KB 7c4e5b14 about 6 years Brian O'Connor adding line to natnet.py
numberedports.py 2.07 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
popen.py 1023 Bytes 50cebe67 over 8 years Bob Lantz Add pmonitor() to make it easy to monitor popen...
popenpoll.py 932 Bytes 9a73dcad about 7 years Brian O'Connor fixed print format in popenpoll
scratchnet.py 1.98 KB a49c85a6 over 8 years Bob Lantz Fix examples to work with new API (and vice-ver...
scratchnetuser.py 2.4 KB bf208cde almost 8 years Brandon Heller Fix SSHD example by generalizing input intf arg...
simpleperf.py 1.47 KB e0bf8ece almost 6 years Bob Lantz Minor code cleanup
sshd.py 2.98 KB a565bdd5 about 6 years cody burkard fix popen to work with shell
tree1024.py 534 Bytes 11782ae0 almost 10 years Bob Lantz Commented out kernel ref, moved to Open vSwitch.
treeping64.py 950 Bytes 2e089b5e almost 8 years Brandon Heller pep8: Fix E127 continuation line over-indented ...
vlanhost.py 3.58 KB eef43402 about 6 years cody burkard check for vlan dependency

Latest revisions

# Date Author Comment
015cd9e7 11/24/2014 08:30 PM lantz

Merge pull request #443 from cdburkard/devel/cluster

use rcmd instead of quietRun when shutting down remote nodes

3d44bcdc 11/24/2014 01:32 AM Bob Lantz

MiniNet -> Mininet

1817cbc3 11/24/2014 01:31 AM Bob Lantz

Pass pyflakes

e0bf8ece 11/24/2014 01:17 AM Bob Lantz

Minor code cleanup

37bdf14b 11/24/2014 01:11 AM Bob Lantz

Rename examples.{intfOptions,multiLink} -> {intfoptions,multilink}

292e69f8 11/24/2014 01:07 AM Bob Lantz

Renamed to intfoptions.py for consistency

dd876e69 11/24/2014 01:04 AM Bob Lantz

DemoCLI -> ClusterCLI

34933ef7 11/19/2014 01:22 AM cody burkard

use ControlPersist ssh option to create a ControlMaster connection that will not die when a node dies

bbf94cdb 11/18/2014 01:55 AM cody burkard

use rcmd instead of quietRun when shutting down remote nodes

dde2263f 11/12/2014 09:29 PM Bob Lantz

Disable shared SSH connections by default.

Note that we do still provide a default if you specify
ControlPath=True

View revisions

README


Mininet Examples

These examples are intended to help you get started using Mininet's Python API.

baresshd.py:

This example uses Mininet's medium-level API to create an sshd process running in a namespace. Doesn't use OpenFlow.

consoles.py:

This example creates a grid of console windows, one for each node, and allows interaction with and monitoring of each console, including graphical monitoring.

controllers.py:

This example creates a network with multiple controllers, by using a custom Switch() subclass.

controllers2.py:

This example creates a network with multiple controllers by creating an empty network, adding nodes to it, and manually starting the switches.

controlnet.py:

This examples shows how you can model the control network as well as the data network, by actually creating two Mininet objects.

cpu.py:

This example tests iperf bandwidth for varying CPU limits.

emptynet.py:

This example demonstrates creating an empty network (i.e. with no topology object) and adding nodes to it.

hwintf.py:

This example shows how to add an interface (for example a real hardware interface) to a network after the network is created.

limit.py:

This example shows how to use link and CPU limits.

linearbandwidth.py:

This example shows how to create a custom topology programatically by subclassing Topo, and how to run a series of tests on it.

linuxrouter.py:

This example shows how to create and configure a router in Mininet that uses Linux IP forwarding.

miniedit.py:

This example demonstrates creating a network via a graphical editor.

mobility.py

This example demonstrates detaching an interface from one switch and attaching it another as a basic way to move a host around a network.

multiping.py:

This example demonstrates one method for monitoring output from multiple hosts, using node.monitor().

multipoll.py:

This example demonstrates monitoring output files from multiple hosts.

multitest.py:

This example creates a network and runs multiple tests on it.

nat.py:

This example shows how to connect a Mininet network to the Internet using NAT. It also answers the eternal question "why can't I ping google.com?"

numberedports.py

This example verifies the mininet ofport numbers match up to the ovs port numbers. It also verifies that the port numbers match up to the interface numbers

popen.py:

This example monitors a number of hosts using host.popen() and pmonitor().

popenpoll.py:

This example demonstrates monitoring output from multiple hosts using the node.popen() interface (which returns Popen objects) and pmonitor().

scratchnet.py, scratchnetuser.py:

These two examples demonstrate how to create a network by using the lowest- level Mininet functions. Generally the higher-level API is easier to use, but scratchnet shows what is going on behind the scenes.

simpleperf.py:

A simple example of configuring network and CPU bandwidth limits.

sshd.py:

This example shows how to run an sshd process in each host, allowing you to log in via ssh. This requires connecting the Mininet data network to an interface in the root namespace (generaly the control network already lives in the root namespace, so it does not need to be explicitly connected.)

tree1024.py:

This example attempts to create a 1024-host network, and then runs the CLI on it. It may run into scalability limits, depending on available memory and sysctl configuration (see INSTALL.)

treeping64.py:

This example creates a 64-host tree network, and attempts to check full connectivity using ping, for different switch/datapath types.

vlanhost.py:

An example of how to subclass Host to use a VLAN on its primary interface.

Also available in: Atom