Using Mininet Oliveira
Using Mininet Oliveira
net/publication/269292945
CITATIONS READS
401 9,984
4 authors, including:
SEE PROFILE
All content following this page was uploaded by Rogerio Leão Santos de Oliveira on 12 June 2015.
Abstract— Software-Defined Networks (SDNs) represents an systems are being connected to the network. Indeed, the
innovative approach in the area of computer networks, since they concept of computer networks is beginning to seem somewhat
propose a new model to control forwarding and routing data outdated, considering the large number of non-traditional
packets that navigate the World Wide Web. Since research on equipment being connected to the Internet [1].
this topic is still in progress, there are not many devices such as
routers and switches that implement SDN functionalities; In the meantime this worldwide network of computers
moreover, the existing ones are very expensive. Thus, in order to known as the Internet provides communication around the
make researchers able to do experiments and to test novel world, even though promoting sometimes dependence in the
features of this new paradigm in practice at a low financial cost, users, it faces a problem. The level of maturity in its structure
one solution is to use virtual network emulators. As a result, this
paper focuses on study and evaluation of SDN emulation tool
also reduced its flexibility. Implementations of new
called Mininet. Initial tests suggested that the capacity of rapid technologies often require replacement of hardware devices
and simplified prototyping, the ensuring applicability, the (routers and switches), what can be very expensive and very
possibility of sharing results and tools at zero cost are positive hard-working for network administrators.
factors that help scientists boost their researches despite the The research community of computer networks has been
limitations of the tool in relation to the performance fidelity searching for solutions that enable the use of networks with
between the simulated and the real environment. After
presenting some concepts of this paradigm, the purpose of its
more programming resources and less need for replacement of
appearance, its elements and how it works, some net prototypes hardware elements, so that new technologies designed to solve
are created to better understand the Mininet tool and an new problems can be inserted gradually into the network and
evaluation is done to demonstrate its advantages and without significant costs.
disadvantages. The section 2 of this paper discusses the SDN paradigm
reporting its motivation, the network elements that are part of
Keywords — Software Defined Networking, emulation, this new structure as well as the operation of these components
OpenFlow, virtualization, Floodlight, Mininet. by comparing them to the traditional structure. The content of
section 3 presents the simulation tool called Mininet and also
I. INTRODUCTION describes some SDN controllers. The section 4 proposes an
It is evident the immense success of the computer networks environment simulation using the presented SDN tools where
today. Majority of the people’s activities, directly or indirectly, tests are performed. These tests provide us results to discuss the
use resources or services offered by communication networks. topic of this work in section 5. Finally, section 6 describes
other network simulators and section 7 presents the conclusion
The Internet is a computer network that interconnects and suggestions for future works.
thousands of computing devices around the world. A little time
ago, these devices were basically desktop computers, II. SOFTWARE-DEFINED NETWORKS
workstations, and so-called servers that store and transmit
information, such as web pages and e-mail messages. To mitigate flexibility problems, the complex
However, more and more devices such as TVs, laptops, game administration of the current networks, the researchers of
consoles, cell phones, webcams, cars and electronic security computer networks have invested in initiatives that implements
networks with greater programming capabilities and reduce the
C. Scalability tests.
Even in this environment, some scalability tests were done.
Fig. 1. Simulation topology. They will be explained in the following section. We created a
bash script that initiates different virtual networks topologies in
The follow command line was used to create the proposed Mininet, prints the amount of memory used up to this point,
scenario. destroys the virtual network and prints the time spent on the
mn –topo=linear,2 entire procedure. The script mentioned is transcribed below.
After creating the scenario, we execute a test of connection #!/bin/bash
using the packet ICMP (echo-request "ping") from hosts 1 to for n in `seq 1 6`; do
host 2 as the following command line: echo "n: $n"
h1 ping –c1 h2 echo -e "h1 free -m | grep ^Mem | awk '{print \"mem: \"
\$3}'\nexit" | \
The ICMP test execution succeeded, hence, no packet loss
mn --topo tree,$n 2>&1 | \
occurs. It is important to emphasize that no additional
configuration was set on the switches or controller, so the grep -E "^(mem:|completado em)"
communication was only successful because the ICMP packet done
sent from host 1 to host 2 when arrived at switch 1 which has The script execution results are displayed in Figure 3.
no forwarding rule on your flow table, so it sent the packet to
the controller which forwarded it to switch 2.
It is very negative for the packet forwarding performance in
the network if none of both switches has its respective flow
tables, because all packets will pass through the controller
before reaching its end destination. This way, there is
significant dependency and likely network controller
congestion.
To demonstrate this negative dependency on the controller,
some other tests were also run in this scenario.
The controller was disconnected from the switch and the
same communication test with the ICMP packet between host 1 Fig. 3. Scalability test results.
and host 2 was repeated. As a result, the communication cannot
be established, generating 100% packets loss. This happened It is noted that for the creation of small virtual networks,
because the switch 1, which has no forwarding rule upon the spent time is also very short and this time increases with the
receiving the ICMP packet, tried to send it to the controller, but increase of virtual nodes number. For example, the Mininet
this one was absent and caused the error. took approximately 64 seconds to create a tree topology with
255 nodes, while with 511 nodes, the time spent substantially
After that, with the controller disconnected, the forwarding increased for about 242 seconds. The graphic in Figure 4
rules were directly set in flow tables of the both switches and illustrates it.
the communication test with ICMP packet was repeated again.
The result was successful. The ICMP packet could reach its In relation to the amount of memory used for creating the
destination, because of the inserted rules on the switches; these virtual networks, as illustrated in Figure 5, while the number of
ones did not need the controller for forwarding the packets. nodes was little, the Mininet showed a lower memory
Figure 2 displays the rules set in switches' flow tables. consumption. This memory consumption was practically the
same until virtual network creation with 127 nodes where
It is important to remember that these rules were manually increased linearly after that.
added to the flow tables of switches as the following line
which provides no guarantee that a host that is ready to send a
packet will be scheduled promptly, or that all the switches will
forward at the same rate [10].
The Mininet currently runs on a single machine and
emulates all hosts, switches and links in a single operating
system. All these elements share the same hardware resources,
what is a disadvantage for experiments on a larger scale.
B. Prototyping
Although not suitable for large-scale simulations which
require significant amounts of nodes, the Mininet is a great
software for prototyping small and medium networks.
Students, researchers, network administrators and other
Fig. 4. Graphic displaying the time spent for creating and destroying the stakeholders with a simple laptop can use Mininet for rapid
virtual networks. prototyping of a SDN idea. The short startup time and low
overhead enable exploring a design space and making a
Another paper [10] also made some scalability tests like medium scale system that runs on a modest hardware. Several
those ones and excepting only the differences found in the researchers can share scripts, configurations, topologies and
processing power of hardware used in both tests, the results work on prototypes simultaneously without interference.
were similar. Mininet begins to take longer to create and
destroy virtual networks and use much memory space when the C. Applicability
number of virtual networks becomes larger.
One of the most important requirements for any emulator
software is the applicability. In this context, all implemented
resources and ideas in a simulation environment must function
properly in real environments without significant changes.
The Mininet proves this capability since it allows those
tests performed in a simulated environment to be able to be
easily shared to other test infrastructure, independent on
hardware or even in a production environment.
D. Sharing
Thus the ability to share is perhaps one of the strongest
points of the emulator Mininet. A project, a topology or a test
code can very easily be distributed to the entire research
community. The emulator itself, when downloaded from the
Fig. 5. Gráfico representando a memória ocupada para as redes. official website [8], includes in the virtual machine package
initially, the Mininet, a variaty of different tools to perform and
analyze SDN prototypes, and a set of sample codes that create
V. RESULTS AND DISCUSSIONS. different SDN topologies and facilitate the development of
This new paradigm called Software-Defined Networks research.
(SDN) has received great attention from the scientific Moreover, it is also possible that researchers who create
community and from the network management system
additional tools, sample codes and different SDN settings can
manufacturers. Being a current topic with innovative trends
share them with other researchers. To do so, it is necessary just
and providing various application possibilities, this paradigm is
generate a new image for the virtual machine and distribute
being called "The Future of Internet" [11]. Therefore, many
manufacturers and researchers joined the idea of a network them over the internet.
structure defined by independent applications of hardware and
no longer just based on the principle of traditional IP Routing. VI. ANOTHER NETWORK SIMULATORS
The emulator software Mininet studied in this paper brings IMUNES [13] added virtual Ethernet interfaces and a
a unique contribution to the advancement of research on SDN feature similar to network namespaces into the BSD Kernel. It
paradigm and after performing several tests and reviewing enables rapid prototyping, but in itself it does not provide a
researcher studies, here are some considerations. path to hardware deployment or a means for distribution and
sharing.
A. Limitations EMULAB [14] took another OS-level virtualization
Currenty, the most significant limitation of Mininet is its tecnhonology, FreeBSD jails, and modified it to allow multiple
lack of performance fidelity, especially at high loads. CPU virtual interfaces per process group, similar to network
resources are multiplexed in time by the default scheduler, namespaces. EMULAB virtual nodes present a different design
point, emulating 10 or more nodes on a single PC with close Using the Mininet tool addressed in this paper, it is also
fidelity. Despite implementing lightweight virtualization possible to conduct further researches into Software-Defined
techniques, these tools do not support the OpenFlow protocol. Networks. Questions such as what the most appropriate
network abstraction is, how to implement clearance
Nowadays, very few network simulators support the mechanisms and how to configure the controllers to ensure best
OpenFlow protocol; one is ns-3 [15]. The ns-3 tool simulates reliability, performance and security, still represent a wide
the operations of an Open-Flow switch by compiling and variety of topics that can be explored.
linking an Open-Flow switch C++ module with its simulation
engine code. To simulate a real OpenFlow controller, ns-3 also
implements it as a C++ module, and compiles and links it with REFERENCES
its simulation engine code. There is a project of ns-3 for [1] K. F. James and R.W. Keith, “Computer Networks: A Top-Down
supporting the OpenFlow protocol, but only the version 0.89 of Approach”, 5th ed. Person Addison Wesley, 2010, pp. 1-50.
the OpenFlow protocol is supported, which is quite old as the [2] T. L. David and W. J. David, “Towards an active network architecture.”
latest version is already 1.3.2. in SIGCOMM Comput. Commun. Rev., vol. 37, no. 5, pp. 81-94, Oct.
2007.
Another OpenFlow network simulator and emulation is [3] P. Larry and R. Timothy, “The design principles of planetlab.” in
EstiNet [16]. EstiNet uses a unique approach to testing the SIGOPS Oper. Syst. Rev., vol. 40, no. 1, pp. 11–16, Jan. 2006.
functions and performances of OpenFlow controllers. By using [4] GENI. (2010, Mar). Global Environment for Network Innovations:
Spiral 2 overview. GENI. [Online].Available: http://www.geni.net/
an innovative simulation methodology, which is called kernel [5] M. Nick et al., “OpenFlow: enabling innovation in campus networks”,
re-entering [17], EstiNet combines the advantages of both the ACM SIGCOMM Computer Communication, vol. 38, no. 2, pp. 69-74,
simulation and emulation approaches. In a network simulated Apr. 2008.
by EstiNet, each simulated host can run the real Linux [6] C. Martin et al., “Ethane: Taking control of the enterprise.” in
operating system, and any UNIX-based real application Proceedings of the 2007 conference on Applications, technologies,
architectures, and protocols for computer communications, vol. 37, no.
program can readily run on a simulated host without any
4, pp. 1–12, Oct. 2007.
modification. Although EstiNet also supports the OpenFlow [7] C. Martin et al., “Rethinking enterprise network control.” in IEEE/ACM
protocol and can be used to simulate SDNs, easy sharing Transactions on Networking, vol. 17, no. 4, pp. 1270-1283, Aug. 2009.
results and tools with researchers is a Mininet advantage. [8] Mininet. (2013, Mar). An Instant Virtual Network on your Laptop (or
other PC). [Online]. Available: http://mininet.org/
[9] Floodlight. (2013, Mar). Open Source Software for Building Software-
VII. CONCLUSIONS AND FUTURE WORKS Defined Networks. [Online]. Available:
This paper aimed to evaluate the SDN emulation tool called http://www.projectfloodlight.org/floodlight/
[10] L. Bob et al., “A network in a laptop: rapid prototyping for software-
Mininet. defined networks.” In Proceedings of the Ninth ACM SIGCOMM
In the first sections of this paper the SDN paradigm, its Workshop on Hot Topics in Networks, Hotnets, vol. 10, no. 19, pp. 1-6,
Oct. 2010.
purpose, its elements and its operational structure were [11] D. D. M. Marcelo et al., “Internet do futuro: Um Novo Horizonte,” in
introduced. The Mininet, the Floodlight controller and other Simpósio Brasileiro de Redes de Computadores, 2009, pp. 1-59.
SDN tools were presented and used for prototyping and [12] OpenFlow (2013, Jul). OpenFlow 1.3.2 Specification. [Online].
simulation. Other researches results were also referenced in this Available:https://www.opennetworking.org/images/stories/downloads/sd
study. n-resources/onf-specifications/openflow/openflow-spec-v1.3.2.pdf
[13] M. Zec and M. Mikuc. Operating system support for integrated network
After performing several tests and simulations, we emulation in imunes. In Proc. of the 1st Workshop on Operating System
concluded in this paper that despite the limitations of the tool in and Architectural Support for the on demand IT InfraStructure (OASIS),
2004.
relation to the fidelity of performance between the simulated [14] M. Hibler et al., Large-scalevirtualization in the emulab network testbed.
and the real environment, the Mininet tool has great importance In USENIX 2008 Annual Technical Conference. USENIX, 2008, pp.
for SDN research. In practice, waiting a few seconds for full 113-128.
larger topologies to start is quite reasonable and faster then the [15] T. R. Henderson et al., “Network Simulations with the ns-3 Simulator,”
boot time for hardware switches. Moreover, the capacity of ACM SIGCOMM ’08, Seattle, WA, Aug. 17–22, 2008.
[16] EstiNet 8.0 OpenFlow Network Simulator and Emulator, EstiNet
rapid and simplified prototyping, the applicability safety, the Technologies Inc., http://www.estinet.com.
possibility of sharing results and tools at zero cost are positive [17] S. Y. Wang and H. T. Kung, “A Simple Methodology for Constructing
factors that help scientists to boost their researches. Extensible and High-Fidelity TCP/IP Network Simulators,” IEEE
INFOCOM ’99, New York, Mar.21–25, 1999.
Mininet has been used by over 100 researchers in more than
18 instituions, including Princeton, Berkeley, Purdue, ICSI,
UMass, University of Alabama Huntsville, NEC, NASA,
Deutsche Telekom Labs, Standford, and a startup company, as
well as seven universities in Brazil [10]. This fact is a good
indicator of advantages of this tool.
Future works could research about Mininet with other
external controllers and also compare the performance results
among it and other network simulation tools, such as PlanetLab
[3], GENI [4] and EstiNet [16].