SDN Lab
SDN Lab
Lab
Using Mininet
and the
POX Controller
Last Update 2014.02.04
2.1.0
Sources
This lab uses the OpenFlow Tutorial
sample lab from
http://archive.openflow.org/wk/index.php
/OpenFlow_Tutorial#Download_Files
and content from the book Software
Defined Networking with OpenFlow by
Siamak Azodolmolky
What is Mininet
Mininet is a network emulator, not a
simulator
It can be used to create virtual hosts,
hubs, switches, controllers, and links
The code used in Mininet can be used with
no or minimal changes on real SDN
OpenFlow networks
10
Check Linux
Mininet is a command line tool that runs in
Linux
The Mininet prompt looks like this
mininet>
11
Check Linux
We will use the sudo command to run the
Linux commands with root privileges at
the normal user prompt
12
Check Linux
Start the virtual machine
Login to Linux
The login is
mininet
mininet
13
Check Linux
14
Check Linux
Lets see if the two network interfaces are
setup correctly
At the Linux prompt enter
ifconfig
15
Check Linux
Three interfaces should appear
Two physical interfaces called
eth0
eth1
And the loopback interface
16
Check Linux
One of the physical interfaces should have
a 192 address and the other a 10 address
We will access the virtual machine using a
terminal program using the 192 address
If either of the eth Ethernet interfaces are
missing, run this command
sudo dhclient ethx
17
Check Linux
18
Check Linux
As you can see the eth1 interface is
missing
After the dhclient command is run this
appears
19
Check Linux
20
21
22
23
24
25
26
27
28
29
30
An OpenFlow Switch
This is a software based switch that takes
commands from the controller that are used to
handle the frames it receives
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
Activate Wireshark
Wireshark is useful here to examine the
traffic generated by OpenFlow
The virtual machine being used for this lab
has Wireshark already installed
Lets see how we get it working in this
environment
We will have to use a new SSH session
using X11 as Wireshark uses a GUI
interface
Copyright 2014 Kenneth M. Chipps Ph.D. www.chipps.com
55
Activate Wireshark
To run an application that uses a GUI X11
is required
This can be done at either end
Under Windows, the Xming server must
be running, and you must make an SSH
connection with X11 forwarding enabled
56
Activate Wireshark
First, search the Internet for and download
the Xming server
Install it
Start Xming
Xming will not show any window, but you
can verify that it is running by looking for
its process in Window's task bar
Copyright 2014 Kenneth M. Chipps Ph.D. www.chipps.com
57
Activate Wireshark
Second, make an SSH connection with
X11 forwarding enabled
If you are using Putty, you can connect to
the lab by entering the VM's IP address
for the 192 address NIC and enabling X11
forwarding
58
Activate Wireshark
To enable X11 forwarding from Putty's
GUI, go to PuttyConnection | SSH | X11,
then click on Enable X11 Forwarding, as
shown in the following screenshot
59
Activate Wireshark
60
Activate Wireshark
Or X11 can be added to the VM itself
To install X11 and a simple window
manager, from the VM console window
enter
$ sudo apt-get update
$ sudo apt-get install xinit flwm
61
Activate Wireshark
Now start Wireshark as a background
process
$sudo wireshark $
62
63
64
POX Controller
POX is NOXs younger sibling
At its core, its a platform for the rapid
development and prototyping of network
control software using Python
Meaning, at a very basic level, its one of a
growing number of frameworks (including
NOX, Floodlight, Trema, etc., etc.) for helping
you write an OpenFlow controller
65
POX Controller
POX also goes beyond this
As well as being a framework for interacting
with OpenFlow switches, were using it as the
basis for some of our ongoing work to help
build the emerging discipline of Software
Defined Networking
Were using it to explore and prototype
distribution, SDN debugging, network
virtualization, controller design, and
programming models
Copyright 2014 Kenneth M. Chipps Ph.D. www.chipps.com
66
67
68
69
70
Summary
We now have a complete Software
Defined Network whose actions are
defined by OpenFlow
71