Documente Academic
Documente Profesional
Documente Cultură
A Report Submitted
in Partial Fulfillment of the Requirements
for the Degree of
Bachelor of Technology
in
Computer Science & Engineering
by Group CS08
Abhyudaya Anand, Adarsh Pandey, Kunal Sharma, Amish Kumar,
Krishna Murari, Sudhir Kumar Jayaswal
to the
COMPUTER SCIENCE AND ENGINEERING DEPARTMENT
MOTILAL NEHRU NATIONAL INSTITUTE OF TECHNOLOGY
ALLAHABAD
May, 2017
UNDERTAKING
I declare that the work presented in this report titled “Bandwidth-Delay Con-
strained Application Aware Routing In Software Defined Networks”, submit-
ted to the Computer Science and Engineering Department, Motilal Nehru
National Institute of Technology, Allahabad, for the award of the Bache-
lor of Technology degree in Computer Science & Engineering , is my
original work. I have not plagiarized or submitted the same work for the award
of any other degree. In case this undertaking is found incorrect, I accept that
my degree may be unconditionally withdrawn.
May, 2017
Allahabad
(Abhyudaya Anand)
ii
CERTIFICATE
May, 2017
iii
Preface
The basis of our thesis is to explore the potential of Software Defined Networks(SDN)
in efficent traffic engineering. It is written to provide a fast routing algorithm for
today’s application centric dynamic networks. Since the evolution of SDN, it’s
implementation in real networks has been a major issue.Algorithms used for traffic
engineering in real time are a major research issue.We used floodlight controller to
study current algorithms used for the task and our thesis aims to provide a more
diverse solution which can later be integrated into the controller.
The idea for the project was conceived under the guidance of our mentor Dr.
Shashank Srivastava. Our project work was decided together by our group and
mentor as he was already working on congestion controlled path assignment in SDN
networks by modifying the routing algorithms used by the controller. We have
worked on one of the use cases(Application Aware Routing(A2R)) for our algorithm.
The results of thesis can be implemented by anyone who has a basic idea of
how routing algorithms are implemented and how link metrics are used in floodlight
controller.
iv
Acknowledgments
We would like to express our sincere gratitude to Dr.Shashank Srivastava for provid-
ing us the golden opportunity to do this wonderful project on the topic Bandwidth-
Delay Constrained Application Aware Routing In Software Defined Networks which
also helped us to learn and explore more about networking and networking devices.
We would also like to thank all the PhD. Scholars working under Dr. Shashank
Srivastava for their proper guidance and encouragement in carrying out this project
work in limited time frame.
v
Contents
Preface iv
Acknowledgments v
1 Introduction 2
1.1 Problem Statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.2 Motivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.3 Approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
vi
4.1.1 Application Aware Routing . . . . . . . . . . . . . . . . . . . 16
4.1.2 Path Cache . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
4.1.3 Shortest Path Algorithms . . . . . . . . . . . . . . . . . . . . 21
4.2 Network Simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
4.2.1 Tools Used . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
4.2.2 Environment Setup . . . . . . . . . . . . . . . . . . . . . . . . 26
5 Results 27
6 Future Works 34
6.1 Shortest Path Algorithm . . . . . . . . . . . . . . . . . . . . . . . . . 34
6.2 Application Aware Routing . . . . . . . . . . . . . . . . . . . . . . . 34
7 Conclusion 36
References 37
References 38
vii
List of Figures
1
Chapter 1
Introduction
1.2 Motivation
In Software Defined Networking, [1] the network intelligence is separated from the
data plane and logically centralized in a programmable controller.This concept opens
the potential of network to provide efficient traffic engineering(TE) and better Qual-
ity of Service(QoS) due to centralized system and a global view of network.SDN
2
network devices could be dynamically handled by the control software in order to
ensure optimal allocation of the network resources and avoid congestion.
TE algorithms proposed so far works on setting up bandwidth guaranteed traffic
tunnels in the network.[2] With wide emergence of real time internet application
these algorithms can’t work properly because they create bottlenecks in the network.
Algorithm implemented in current floodlight controller uses yen’s algorithm and
some path metrics(utilization,latency etc.) to provide better resource utilization.[4]
But it can’t handle multiple path metrics.
This motivated us to consider a model of control plane which provide application
specific paths in the network and do so without being affected by future traffic.
1.3 Approach
In analysis of current routing algorithm we aim to implement different path met-
rics at same time and plot relevant graphs. We also aim to implement different
routing algorithms for single, single source shortest path calculation and k-shortest
path calculation.For options we are aiming to implement Bellman Ford and A-star
algorithms in place of Dijkstra and Hershberger algorithm in place of yen. To use
different path metrics we aim to implement packet dissection for Application Aware
Routing(A2R).
To implement traffic engineering(TE) in real time we aim to reduce number of
re-computations by implementing a path cache. This path cache stores time of hit,
path metric and path assigned between a (ingress-egress) pair. By this PACKET IN
packets of continuous traffic flow do not need re-computation of topology even if path
metric of network has changed.
3
Chapter 2
2.1 Background
4
• Network delay, latency - The term latency is used to refer to delay in data
communication that happens over a network.This may prevent the data from
taking full advantage of the network and effectively decreases the communica-
tion bandwidth.
• Data loss and network errors - Data loss refers to packets that may get
dropped while transmission over the network, it also encompasses packets that
may be lost or re-transmitted due to errors in transmission an subsequent
corrupt information.
• With rapid growth in cloud computing and the demand of massive-scale data
centers, network management should be able to improve resource utilization
for better system performance.
Traffic engineering mechanisms in SDN can be much more efficiently and intel-
ligently implemented as a centralized Traffic Engineering system compared to the
5
conventional approaches because of the major advantages of the SDN architecture.
More specifically,SDN provides
3. Multiple flow table pipelines in OF switches can make flow management more
flexible and efficient.
6
According to the basic operation of flow management in SDNs, when a flow arriv-
ing at switch does not match any rules in the flow table, it will send the first packet
of the flow to the controller,the forwarding path for the flow will be computed by the
controller, the controller will send the appropriate forwarding entries to install in the
flow tables at each switch along the planned path, and all subsequent packets in the
flow or even different flows with matching attributes will be forwarded in the data
plane along the path and will not need any control plane action. In this operation,
if the aggregated traffic consists of high number of new flows, a significant overhead
can be yielded at both the control plane and data plane. Moreover, the forward-
ing rule setup can also take time, so that the latency can be increased. Therefore,
to solve these problems, traffic engineering mechanisms for the flow management
should be designed to address the tradeoffs between the latency and load-balance.
To ensure the network reliability, SDN should have a capability to perform fail-
ure recovery transparently and gracefully, when a failure occurs in the network
infrastructure (i.e., controllers, switches and links) [5].To increase the networking
resiliency of SDN, in OF v1.1+, a fast failover mechanism is introduced for link or
node failures, in which an alternative port and path can be specified, enabling the
switch to change the forwarding path in the policy based routing without requiring
a round trip to the controller. Although the situation is much improved with cen-
tralized network management, achieving fast failure recovery is still very challenging
in SDN, because the central controller in restoration must calculate new routes and
notify all the affected switches about the recovery actions immediately. Moreover,
the failure recovery needs to consider the limited memory and flow table resources
at switches.
The topology update mechanism in SDNs focuses on the planned changes such as
the network policy rule changes, instead of the network element or link failures. Since
the centralized controllers manage all switches in SDN/OF networks by dynamically
configuring the global network policy rules, a certain level of required consistency
of the network policies needs to be guaranteed across the switches so that each
individual packet or flow should be handled by either the old policy or the new policy,
but not by the conflicting combinations. Moreover,during the policy updating time,
7
the affected flows may be dropped or delayed, which degrades the network QoS
performance or leads to wasting network resources. Therefore, the key challenge
in topology update is how SDN controller can efficiently update the network with
required consistency in (near) real time.
8
fact that the maximum available bandwidth of certain links is 2Gbps while of others
varies upto 8Gbps.
The latency metric takes into consideration the real time latency between the
links and uses them for weight assignment. Latency due to electrical factors over
the link is constant and does not vary in real time.While the latency due to network
congestion keeps varying according to the traffic flowing over the network.The metric
implemented in floodlight only takes into account the latency of the link present due
to electrical factors.The weight assignment here is to favor links with lower latency,
and to reduce the overall delay in communication over the network.However the
nature of paths decided does not change due to static nature of the metric considered.
The link-speed metric in floodlight focuses only upon the total bandwidth of
each link irrespective of the real time utilization of the links.This approach however
at times may result in congestion in networks because only the higher availability
links get lower weights, which is not changed later on.Thus resulting in congestion
over certain links and the network being underutilized in several cases.
The metrics for hop count are the basic metrics which only take into consideration
the total number of links that a packet need to traverse in its path from source to
destination. In order to implement this approach using the concept of metrics, all
the links are assigned equal weights. This assignment results least cost paths which
eventually also have the minimum number of hops.
After assignment of the weights according to the metrics, the floodlight controller
finds the least cost paths for the given source destination pairs.The algorithms used
are for finding both the single shortest path and K-shortest paths.This also involves
periodic re-computations of paths to account for the dynamic metrics which keep on
changing according to the conditions of the network, resulting in real time calculation
routes which are optimal.
9
2.2 Single Source Shortest Path Algorithms
10
shortest path is calculated. To avoid this we calculate and store k shortest paths
between source and destination. When path metric is changed we just check these
paths for that metric and choose the best one. We have used two algorithms to cal-
culate k-shortest paths. First is yen’s algorithm and second is hershberger’s rotation
algorithm.
11
Chapter 3
12
Also, in a network, there may be more than one path (route) between any pair
of entity. Each of these paths may have different property. For example, one path
may be able to provide higher bandwidth while the other may have lower latency.
With recent technology such as tunneling, overlay network and virtualized network,
it is becoming increasingly difficult to find an appropriate path for the application,
as a shortest path is not necessarily always the best path anymore.
13
3.3 Implementation of A2R with SDN
A Software-Defined Network (SDN) is a technology that allows researchers to do
networking experiment such as testing new network protocol at the actual network
line speed using standard devices. Open Flow, an implementation of SDN, provides
standardized interfaces to be implemented by vendors.Unlike traditional networking
paradigm, Open Flow splits a network into data plane and control plane. Data plane
is underlying mechanism of a switch that handles actual data movement from one
interface to others. Control plane is the part that handles routing decisions such as
which packet goes to where. In traditional network, data plane and control plane
reside together in each switch. However, Open Flow separates control plane out
into centralize programmable component called Open Flow controller. When any
event occurs at the switch, it notifies the controller of the event. The controller then
makes a decision according to how it is programmed and sends a response back to
the switch to tell it how it should behave. The result is sent back in a form of new
entry to flow table in the switch. This flow table will be used for future decision
instead of consulting with the controller whenever anything occurs. Using an SDN
implementation such as Open Flow, it is now possible to implement application-
aware networking without being limited by traditional paradigm of network analysis,
which relied on line-rate packet analysis. With Open Flow, it is now possible to
allocate different route specifically to each connection of an application.
14
In our project, we have analyzed the packets that are received at the controller.
Its different layers are extracted and information about the packet is analyzed.
Transport layer uses ports t multiplex packets among different applications. Since
various applications like Web Server, FTP server runs on standard port, transport
layer port number can be used to identify the type of application to which the
packets belong to.The flow info object is obtained and is sent into flow classifier and
the flow is classified.
15
Chapter 4
16
4. Reducing path re-computations for different application dependent routing
metrics by implementing a path cache on the server.
The classification of packets for application aware routing is done based upon
protocols from the network layer to the application layer of the protocol stack.The
first distinction is made between IP and ARP packets.The packets detected to be of
the IP layer are further dissected while those of the ARP protocol are simply routed
over the default configuration provided by floodlight i.e of minimum hop routing.
For the IP packets, further analysis is required to distinguish between the packets
being either UDP or TCP.This classification can then be used to broadly classify
the packets and estimate the type of metric required.Bandwidth and latency are
two major factors that have the most impact to performance of network applica-
tions. However, not all applications are affected by those two factors equally. Some
application may perform better when more bandwidth is available while others are
benefit more from lower latency. Therefore, we categorize application into two types,
bandwidth-oriented application and latency-oriented application based upon the
transport layer protocol.
Bandwidth-oriented application is a category of application that achieves higher
performance when more bandwidth is avail- able. Most applications that involve
transferring a large amount of data fall into this category. Example of application
in this cat- egory includes HTTP, FTP and media (video/audio) streaming.
Latency-oriented application is a category of application that performs better
over low latency network. Usually, applications that involve remote controlling or
real-time communication fall into this category. For example, SSH is considered as a
latency- oriented application. Most online gaming, although using its own protocol,
often fall into this category as well.
Apart from this classification may also be done on the application layer of the
packets, which is devised from the port number used.
17
4.1.2 Path Cache
It is a cache of path,path metric and path hit time(latest when that path has been
pushed into switches). It has a map of PathTime and PathMetric, two data struc-
tures we implemented. PathMetric stores path identifiers and current path metric
and methods to use them and PathTime stores path assigned and it’s hit time.
18
Figure 4: Path cache algorithm flowchart
19
Figure 5: PathMetric
20
4.1.3 Shortest Path Algorithms
• Bellman Ford Algorithm Implementation of algorithm is done in topology
module of floodlight controller. Bellman procedure takes link costs, links and
source as input and provide a broadcast tree. The root of tree depends upon
whether it is destination rooted or source rooted. Path is then extracted from
that broadcast tree.
21
Figure 6: Bellman Ford Algorithm flowchart
22
Figure 7: A star algorithm flowchart
23
24
2. NTOP
ntop (stylized as ntop) is computer software that probes a computer network to
show network use in a way similar to what the program top does for processes.
In interactive mode, it displays the network status on the user’s terminal. In
Web mode, it acts as a web server, creating a HTML dump of the network sta-
tus.Here for our project we have used ntop tools to generate different network
graphs.
3. IPERF
Iperf is a commonly used network testing tool that can create Transmission
Control Protocol (TCP) and User Datagram Protocol (UDP) data streams
and measure the throughput of a network that is carrying them. Iperf is a
tool for network performance measurement written in C.
25
4.2.2 Environment Setup
The simulation encvironment was setup using mininet to simulate the openflow
switches, Iperf was used for traffic generation and ntop tool was used to monitor the
various network interfaces.The controller used was floodlight.
The steps involved for the environment setup
• Mininet was setup as virtual machine and different kinds of topologies were
simulated using miniedit.
• The iperf tool helped in setting up a few servers over the simulated hosts.Other
hosts were made to communicate with the servers for periodic intervals to
generate traffic over the network.
• The ntop tool was also setup as a part of the virtual machine housing mininet.
• Ntop provided with real time traffic analysis and status of various links on the
network.
26
Chapter 5
Results
The network topology used for testing various metrics consists of 7 switches con-
nected to a central controller. Some of the hosts acted as servers while others were
used as clients.
The other topology used for simulation consisted of 6 switches two of which have
27
been arranged on alternate paths , one of which is selected on the usual metrics
while on other both have traffic.
Figure11 shows topology re-computation time for different shortest path algo-
rithms for different size of networks. Tree topologies of different heights have been
used for it. This shows that as number of levels increase both number of switches
and time of re-computation increase exponentially. A* is performing a little better
than dijkstra due to using heuristic approach.
Figure12 represents traffic on switches s2,s5 and s7 with hop count as path
metric. This shows that all traffic passes by switch s5 because path s1-s5-s4 has
minimum hop count. This is floodlight controller’s default path metric and used for
comparison only in our application.
Figure13 represents network state with utilization as path metric. This shows
that at start all traffic is on single switch but as traffic increases it balances it by
directing some traffic to other paths. Some of other paths are of more hop count
28
Figure 11: Re-computation time of different shortest path algorithms
than minimum. Here some traffic is on s2 too which is in the path of higher hop
count.
Figure14 represents network state with latency & utilization as path metric.
Latency here represents static latency. This path metric is created by using both
parameter statistics. This parameter uses maximum bandwidth to implement uti-
lization balance. This shows that by using this metric network resource utilization
is better. Traffic is divided according to latency and maximum bandwidth.
Figure15 represents network state with latency as path metric. This shows that
low latency
29
Figure 12: Network state with Hopcount as metric
30
Figure 13: Network state with Utilization as metric
31
Figure 14: Network state with Latency & Utilization as metric
32
Figure 15: Network state with Latency as metric
33
Chapter 6
Future Works
• When testing with real-world traffic, it is felt that initial Port based traffic clas-
sification is not sufficient to identify various applications as most of web traffic
including audio, video & streaming content runs on port-80. One solution to
overcome this problem is to parse the HTTP header and using Content-Type
34
to classify the traffic.
35
Chapter 7
Conclusion
36
References
[1] Open Networking Foundation, ”Software defined networking: the new norm for
networks,” Web white paper.
[2] Q. Ma, and P. Steenkiste. ”On path selection for traffic with bandwidth
guarantees,” IEEE international conference on network protocols; 1997.
37
[9] Jin Y. Yen ”Finding The K shortest Loopless Paths in a Network”. MAN-
AGEMENT SCIENCE; 1971.
[11] J. Hershberger and S. Suri. Vickrey ”Prices and shortest paths: What
is an edge worth?”. In Proceedings of the 42nd Annual IEEE Symposium on
Foundations of Computer Science; 2001.
38