final
TRANSCRIPT
An Energy Efficient Load Balancing Algorithm for Cloud
Computing Using Ant Colony Optimization
Submitted in Partial Fulfillment of the Requirements of the Degree of
Master of Technology
In
COMPUTER SCIENCE AND ENGINEERING
By
MOUSTAFA MOHAMAD NAJM
(Roll no. 147509)
Under the supervision of
Dr. S. RAVI CHANDRA
Assistant Professor
Computer Science and Engineering
Department Of Computer Science and Engineering
NATIONAL INSTITUTE OF TECHNOLOGY, WARANGAL
June 2016
2015-2016 Page i
Approval
This dissertation entitled
“An Energy Efficient Load Balancing Algorithm for Cloud Computing
Using Ant Colony Optimization”
by “MOUSTAFA MOHAMAD NAJM” is approved for the degree of
Master of Technology
Examiners
_________________
_________________
_________________
Supervisor
________________
_______________
_______________
Head of Department
________________
Date: ________________
Place: _______________
2015-2016 Page ii
Declaration
I declare that this written submission represents my ideas in my own words and where
others’ ideas or words have been included, I have adequately cited and referenced the original
sources. I also declare that I have adhered to all principles of academic honesty and integrity
and have not misrepresented or fabricated or falsified any ideas/data/fact/source in my
submission. I understand that any violation of the above sill be cause for disciplinary action
by the institute and can also evoke penal action from the sources which have thus not been
properly cited or from whom proper permission has not been taken when needed.
______________________
(Signature)
____MOUSTAFA MOHAMAD NAJM________
(Name of the student)
. 147509 .
(Roll No.)
Date: __________________
2015-2016 Page iii
NATIONAL INSTITUET OF TECHNOLOGY
(An Institution of National Importance)
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING
WARANGAL – 506004
TELANGANA – INDIA
June - 2016
Certificate
This is to certify that the dissertation work entitled “An Energy Efficient Load
Balancing Algorithm for Cloud Computing Using Ant Colony Optimization” is a
bonafide record of work carried out by “Mr. MOUSTAFA MOHAMAD NAJM (Roll No.
147509)”, submitted to the Department of Computer Science & Engineering, in partial
fulfillment of the requirements for the award of the degree of Master of Technology in
“Computer Science & Engineering” at National Institute of Technology, Warangal during
the academic year 2014-2016.
Dr. S.Ravichandra
Asst. Professor & Project Guide
Department of Computer Science &
Engineering
NIT Warangal
Dr. Ch. Sudhakar
Head of the Department
Department of Computer Science &
Engineering
NIT Warangal
2015-2016 Page I
ACKNOWLEDGEMENT
First and the foremost, I thank my creator (SWT) who has bestowed me health, and
knowledge to complete this study. Peace and blessing of Allah be upon His Prophet
(SAW).
I acknowledge and express deep sense of sincere gratitude to my supervisor, Dr. S.
Ravi Chandra, Department of Computer Science & Engineering, NIT Warangal, for his
patience, motivation, enthusiasm, and continuous support of my study and research. His
guidance helped me in all the time of research and writing of this thesis. It was great
experience working under his supervision. I am extremely grateful for what he has
offered me. I would also like to thank him for his friendship and empathy.
I sincerely thank Dr. Chapram Sudhakar, Head of Department of Computer
Science & Engineering for all his enormous support and insightful comments during my
M.Tech.
Special thanks also go to Prof. B. B. Amberkar who gave me invaluable
recommendation and warm encouragements.
It is my privilege to express my sincere thanks to all the faculty members of
Department of Computer Science & Engineering, NIT Warangal for their valuable
support and timely advice which helped me during my M.Tech in NIT Warangal.
Last but not the least I would like to express my wholehearted thanks to my beloved
parents for having faith in me and all my family members for their love, moral support,
prayers and encouragement throughout my life and thanks all my classmates and friends
who helped me directly or indirectly.
MOUSTAFA MOHAMAD NAJM
2015-2016 Page II
ABSTRACT
Improvement of energy efficiency in cloud computing is an important research
topic nowadays. The reduction of operational costs, generated heat and environment
impact are some of the reasons for this. A 2011 report by Greenpeace found that if global
cloud computing was a country; it would use the fifth most electricity in the world. It is
possible to improve energy efficiency in data centers by running various virtual machines
in a single physical machine. Then load balancing is needed to allocate VM’s to physical
machines. Proper load balancing can help in utilizing the available resources optimally,
thereby minimizing the resource utilization and power consumption as well. Moreover,
modern cloud computing environments have to provide high QoS for their customers
resulting in the necessity to deal with power-performance trade-off.
The objective of this research is to develop an Energy efficient load balancing
algorithm for VM allocation problem using ant colony optimization technique to
minimize energy consumption while providing required QoS for customers in
heterogeneous Environment. The proposed algorithm considers the trade-off between
energy consumption and performance and use current resource information and CPU
capacity factor to achieve the objectives. The proposed algorithm has been implemented
and evaluated by using CloudSim simulator which has been used in most researches
related to resource scheduling in cloud computing.
Keywords: Cloud Computing; Load Balancing; Energy Efficiency; Energy Consumption;
QoS; Resource Management; Virtualization; Virtual Machines Allocation; Ant Colony
Optimization.
2015-2016 Page III
Table of ContentsI
ABSTRACT ...................................................................................................................II
Table Of Figures ........................................................................................................ VI
Table of Tables ......................................................................................................... VII
Table of Abbreviations ............................................................................................ VIII
1. CHAPTER 1 ........................................................................................................... 2
INTRODUCTION ..................................................................................................... 2
1.1. Introduction ..................................................................................................................... 2
1.2. Definition of the problem ................................................................................................ 4
1.3. Motivation ....................................................................................................................... 4
1.4. Objectives ........................................................................................................................ 6
1.4.1 Main objective ......................................................................................................... 6
1.4.2 Specific objectives ................................................................................................... 6
1.5. Organization of Thesis ..................................................................................................... 6
1.6. Conclusion ....................................................................................................................... 7
2. CHAPTER 2 ........................................................................................................... 9
CLOUD COMPUTING ............................................................................................. 9
2.1 Introduction ..................................................................................................................... 9
2.2 Cloud computing features ............................................................................................... 9
2.3 Cloud Components ........................................................................................................ 10
2.3.1 Clients ........................................................................................................................... 10
2.3.2 Datacenter .................................................................................................................... 11
2.3.3 Distributed Servers ....................................................................................................... 11
2.4 Essential Characteristics of cloud computing ................................................................ 12
2.5 Cloud Service Model ...................................................................................................... 13
2.6 Cloud Deployment Model ............................................................................................. 14
2.7 Virtualization ................................................................................................................. 15
2.8 Conclusion ..................................................................................................................... 16
2015-2016 Page IV
3. CHAPTER 3 ......................................................................................................... 18
LITERATURE REVIEW ........................................................................................ 18
3.1 Introduction ................................................................................................................... 18
3.2 Load Balancing in cloud computing environment ......................................................... 18
3.2.1 Goals of Load Balancing in cloud computing ......................................................... 18
3.2.2 Related work to Load Balancing algorithms .......................................................... 19
3.3 Literature Review .......................................................................................................... 22
3.4 Conclusion ..................................................................................................................... 35
4. CHAPTER 4 ......................................................................................................... 37
METHODOLOGY AND PROPOSED ALGORITHM ........................................... 37
4.1 Introduction ................................................................................................................... 37
4.2 Ant Colony Optimization algorithm ............................................................................... 37
4.2.1 Ant In Nature ......................................................................................................... 38
4.2.2 Ant Colony Optimization ....................................................................................... 39
4.2.3 Basic Steps for ACO ............................................................................................... 39
4.2.4 Advantages and disadvantages of ACO ................................................................. 40
4.3 The Bin Packing Problem ............................................................................................... 41
4.4 Proposed Energy Efficiency VM allocation based on ACO ............................................ 43
4.4.1 Problem Representation ....................................................................................... 43
4.4.2 System models and problem formulation ............................................................. 45
4.4.3 The description of the proposed ant colony algorithm ......................................... 47
4.4.4 Interquartile Range (IQR) method for finding dynamic threshold ........................ 51
4.4.5 The complete proposed algorithm ........................................................................ 52
4.5 Conclusion ..................................................................................................................... 58
5. CHAPTER 5 ......................................................................................................... 60
SIMULATION AND EXPERIMENTAL RESULTS............................................... 60
5.1 Introduction ................................................................................................................... 60
5.2 Simulation Environment - CloudSim .............................................................................. 61
5.2.1 CloudSim Characteristics ....................................................................................... 61
5.2.2 The CloudSim Platform .......................................................................................... 61
2015-2016 Page V
5.2.3 CloudSim Data Flow ............................................................................................... 63
5.3 Simulation steps ............................................................................................................ 64
5.4 Simulation Classes ......................................................................................................... 64
5.5 Simulation Settings ........................................................................................................ 65
5.3.1 System Mode ......................................................................................................... 66
5.3.2 Workload Data ....................................................................................................... 66
5.3.3 Simulation parameters .......................................................................................... 67
5.3 Evaluation and experimental results ............................................................................. 68
5.3.1 Number of Active Hosts ......................................................................................... 68
5.3.2 Energy Consumption ............................................................................................. 69
5.3.3 Quality of Service ................................................................................................... 71
5.3.4 Energy and SLA Violations (ESV) ............................................................................ 73
5.3.5 Execution Time ...................................................................................................... 75
5.4 Conclusion ..................................................................................................................... 76
6. CHAPTER 6 ......................................................................................................... 78
CONCLUSION AND FUTURE WORK ................................................................. 78
6.1 Conclusion ..................................................................................................................... 78
6.2 Future Work .................................................................................................................. 79
REFERENCES ............................................................................................................. 80
2015-2016 Page VI
Table Of Figures
Figure 1-1 an example of VM placement in a virtualized environment .......................................... 5
Figure 2-1 three components make up a cloud computing solution ............................................ 11
Figure 2-2 Cloud Computing Architecture ..................................................................................... 13
Figure 2-3 Types of Clouds ............................................................................................................ 14
Figure 4-1 Adaptive behavior of ants ............................................................................................ 39
Figure 4-2 Flowchart of ant colony optimization .......................................................................... 40
Figure 4-3 Packing under Next Fit ................................................................................................. 41
Figure 4-4 Packing under First Fit .................................................................................................. 42
Figure 4-5 Packing under Best Fit .................................................................................................. 42
Figure 4-6 Packing under Worst Fit ............................................................................................... 42
Figure 4-7 Problem representation of VM Allocation ................................................................... 44
Figure 4-8 Interquartile Range Threshold ..................................................................................... 52
Figure 4-9 Data Flow Diagram for proposed algorithm ................................................................ 57
Figure 5-1 Main Entities of CloudSim ............................................................................................ 62
Figure 5-2 CloudSim Work Style .................................................................................................... 63
Figure 5-3 CloudSim data flow ...................................................................................................... 63
Figure 5-4 Number of Active Hosts ............................................................................................... 68
Figure 5-5 Energy Consumption .................................................................................................... 70
Figure 5-6 Average SLA Violation * 100 ........................................................................................ 72
Figure 5-7 Overall SLA Violation * 100 .......................................................................................... 73
Figure 5-8 Energy and SLA Violations ............................................................................................ 74
Figure 5-9 Excution Time ............................................................................................................... 75
2015-2016 Page VII
Table of Tables
Table 3-1 Load Balancing scenarios comparison ........................................................................... 22
Table 5-1 configuration of servers................................................................................................. 66
Table 5-2 Power consumption of server at different load levels in watts .................................... 66
Table 5-3 Simulation parameters .................................................................................................. 67
Table 5-4 Number of Active Hosts ................................................................................................. 68
Table 5-5 Energy Consumption ..................................................................................................... 70
Table 5-6 Average SLA Violation * 100 .......................................................................................... 72
Table 5-7 Overall SLA Violation * 100 ........................................................................................... 73
Table 5-8 Energy and SLA Violations ............................................................................................. 74
Table 5-9 Excution Time ................................................................................................................ 75
2015-2016 Page VIII
Table of Abbreviations
ACO Ant Colony Optimization
CIS Cloud Information Service
COP Combinatorial Optimization Problem
CPU Central Processing Unit
HaaS Hardware as a Service
IQR Inter Quartile Range
IaaS Infrastructure as a Service
MIPS Million Instructions Per Second
PaaS Platform as a Service
PM Physical Machine
QoS Quality of Service
RAM Random Access Memory
SaaS Software as a Service
SI Swarm Intelligence
SLA Service Level Agreement
SOA Service-Oriented Architecture
VM Virtual Machine
VMP Virtual Machine Placement
2015-2016 Page 1
Chapter 1
INTRODUCTION
2015-2016 Page 2
1. CHAPTER 1
INTRODUCTION
1.1. Introduction
In recent years, cloud computing become a new computing model emerged from
the rapidly development of internet. It leads the new IT revolution. It saves businesses the
initial setup, updates and maintenance cost. cloud computing is a heterogeneous
environment which means different hardware characteristics including CPU, memory,
storage and other hardware that offers a rapidly and on-demand wide range of services in
which shared resources, information, software and other devices are provided according
to the clients requirement [1]. It has moved computing and data away from desktop and
portable PCs into large data centers [2]. It has the capability to harness the power of
Internet and wide area network (WAN) to use resources that are available remotely,
thereby providing cost effective solution to most of the real life requirements [2]. This
technology also enables on-demand or utility computing just-in-time resource
provisioning model in which computing resources such as CPU, memory, and disk space
are made available to applications only as needed and not allocated statically based on the
peak workload demand [3].
Energy optimization was identified as one of the major concern to adopt it in full-
fledged manner. Cloud computing infrastructure consumes enormous amount of electrical
energy due to a huge-scale infrastructure involved and AC cooling cost that causes very
high metered bills. For example, in 2006, the cost of electricity consumed by IT
infrastructures in US was estimated as $4.5 billion and tends to double by 2011 [3].
Moreover, studies have shown that data centers around the world consumed 201.8
terawatt hours (TWh) in 2010. This is enough energy to power 19 million average U.S.
households and results in approximately $23.3 billion spent for energy costs. Another
problem is significant CO2 emissions that contribute to the greenhouse effect.
One of the ways to reduce power consumption by a data center is to apply
virtualization technology. This technology provides a promising approach through which
2015-2016 Page 3
hardware resources on one or more machines can be divided through partial or complete
machine simulation, time-sharing, hardware and software partitioning into multiple
execution environments, each of which can act as a complete system. Virtualization
enables dynamic sharing of physical resources in cloud computing environments,
allowing multiple applications to run in different performance-isolated platforms called
VMs in a single physical server. On the other hand, it is essential for cloud providers to
offer reliable QoS for the customers that are negotiated in terms of Service Level
Agreements (SLA), such as minimal throughput and maximal response time or latency of
the system. Therefore, the main challenge is to reduce energy consumption of data
centers while satisfying QoS requirements.
While there are many VMs should be assigned to one physical node, VM
allocation and Load Balancing is needed. Load balancing is considered as one of the
challenges in cloud computing, it is the major factor to improve the performance of the
cloud computing and energy efficiency which is highly considered recently. The current
load balancing algorithms in cloud computing environment is not highly efficient,
because prediction of user request arrivals on the server is not possible. Each VM has
different specification, so it becomes a very difficult to schedule job and balance the load
among nodes and a distributed solution is required [6]. Load management in cloud data
centers must take into account the hardware diversity of hosts, heterogeneous user
requirements and energy consumption.
In this work, we propose a fully distributed VM allocation algorithm based on Ant
Colony Optimization (ACO) technique for dynamic allocation of VMs according to
current resources requirements, while ensuring reliable QoS. The objective of the
allocation is to minimize the number of physical nodes serving current workload,
whereas idle nodes are switched off in order to decrease power consumption. Recently,
we can find many research works that have been done on load balancing in cloud
computing using ACO, but most of these researches concentrated on improving
performance and QoS, some authors worked on power consumption and less works
considered heterogeneous environment. In contrast to previous studies, the proposed
2015-2016 Page 4
approach can effectively reduce the power consumption and handle strict QoS
requirements and heterogeneous infrastructure and heterogeneous VMs.
1.2. Definition of the problem
In cloud, virtualization technology is used for efficient management of resources.
This project focuses on the Infrastructure as a Service (IaaS) model in private cloud
where physical resources are exposed as services. Under this model, users request VM to
the cloud, which are then associated to physical resources. Number of VMs more than
physical resources. To achieve the best performance and reduce the consumed energy,
VMs have to fully utilize the physical resources by adapting to the cloud environment
dynamically, so our problem in this research is how to develop efficient Load Balancing
strategy to appropriately allocate the VMs in physical resources in heterogeneous cloud
computing.
The energy-efficient VM placement problem can be divided in two sub-problems.
The first one is the placement of a requested VM on a host, while the second one is the
optimization of the current VM placement. The focus of this work is the first one.
1.3. Motivation
In practice, powering-up a physical server without any CPU load, consumes more
than 50% of the energy consumed by a server with a fully loaded CPU. Therefore, an
energy efficient VM placement aims to reduce the number of active physical machines,
by increasing the workload in the current active machines. The idea is simple: if the
machine already has a work to do, increasing the amount of work will not increase the
power consumption of the data center significantly. However, waking up a new machine
will impact the power consumption of the data center more significantly, since a machine
in suspended state consumes a little fraction of the power of an active one. The strategy
used to place the VMs must be careful to not overload a host, since it is important to not
violate any Service-Level Agreements (SLAs) between the cloud provider and the client.
2015-2016 Page 5
Figure 1-1 an example of VM placement in a virtualized environment
For example, let us consider the situation depicted in Figure 1-1. We have seven
servers, each of which has a quad-core processor which is capable of executing four
VMs. The system is currently hosting seven virtual machines labeled VM1 to VM7.
Figure 1-1 (a) shows VM allocation in existing algorithm [8] where VM allocated to less
loaded server. Figure 1-1 (b) shows VM allocation in our proposed algorithm where VM
allocated to higest loaded server with considering threshold; a simple process for VM
placement is as follows: Place the first VM on the first server. Place the second virtual
VM on the same server if it can satisfy the resource requirements. If not, add a new
server and place the VM on this new server. Continue this procedure until each of the
VMs has been placed on a server, adding a new server when required. To consider QoS
and avoid overload the server, we can consider upper utilization threshold (e.g 90%). The
set of resulting servers at the end comprises the consolidated server farm. Finally the
number of servers required reduced from 7 down to 3.
For simplicity, we consider fixed threshold in this example. Anyway, the threshold in
our proposal will be calculated dynamically according to utilization information.
2015-2016 Page 6
1.4. Objectives
1.4.1 Main objective
The main objective of this research is to propose an energy efficient distributed
algorithm for VM allocation problem based on ACO technique to achieve power-
performance trade-off in heterogeneous private cloud computing environment.
1.4.2 Specific objectives
The specific objectives of this research are:
1. Study and analyze existing works for load balancing in cloud computing.
2. Study ACO technique, and related works that have been done by using this
technique to solve VM allocation problem.
3. Formulate VM allocation problem as optimization problem.
4. Propose an energy efficient load balancing algorithm based on ACO.
5. Propose an adaptive threshold method for QoS.
6. Implement the proposed algorithm using CloudSim simulator.
7. Evaluate the proposed algorithm using some metrics (e.g. energy consumption,
number of active hosts, QoS and execution time).
8. Compare the results of proposed algorithm with existing algorithm.
1.5. Organization of Thesis
The thesis is organized as follows:
Chapter 1: This chapter describes the research problem and defines the research
objectives. Furthermore, it gives motivation toward the proposed solution.
Chapter 2: This chapter gives an overview of cloud computing, which includes
the terminologies and technologies used in cloud computing.
Chapter 3: This chapter studies and compares different load balancing techniques
in cloud computing. It also reviews recently works that have been done to solve
resource allocation problem in cloud computing based on ACO and discuses the
2015-2016 Page 7
advantages and disadvantages of each work. Furthermore, it focuses on some
works related to energy consumption and QoS in cloud computing.
Chapter 4: This chapter describes proposed algorithm in details. First, it
describes ACO technique and models resources utilization and power
consumption in cloud computing. After that, it formulates VM allocation problem
as combinatorial problem and presents ACO based algorithm to solve this
problem. It describes also IQR method to calculate upper threshold dynamically
using utilization history. Finally, it shows the complete algorithm including
pseudo code and data flow diagram.
Chapter 5: this chapter focuses on the simulation details and experimental results
using CloudSim.
Chapter 6: This chapter describes the conclusion derived from the proposed
work and directions for future research work.
1.6. Conclusion
This chapter gives a brief idea about cloud computing and load balancing. It also
gives an overall idea about the research problem, main and specific objectives and
motivation for proposed solution.
2015-2016 Page 8
Chapter 2
CLOUD COMPUTING
2015-2016 Page 9
2. CHAPTER 2
CLOUD COMPUTING
2.1 Introduction
In case of cloud computing, services can be used from diverse and widespread
resources rather than remote servers or local machines. There is no standard definition of
cloud computing. Generally it consists of a bunch of distributed servers known as
masters, providing demanded services and resources to different clients known as clients
in a network with scalability and reliability of datacenter. The distributed computers
provide on-demand services. Services may be of software resources (e.g. SaaS) or
physical resources (e.g. PaaS) or hardware/infrastructure (e.g. HaaS or IaaS). Amazon
EC2 (Amazon Elastic Compute Cloud) is an example of cloud computing services [10].
The National Institute of Standards and Technology's (NIST) define a Cloud
computing as "cloud computing is a model for enabling ubiquitous, convenient, on-
demand network access to a shared pool of configurable computing resources (e.g.,
networks, servers, storage, applications and services) that can be rapidly provisioned and
released with minimal management effort or service provider interaction. "[4]
The cloud is a virtualization of resources that maintains and manages itself [11]. It
builds on a wide range of different computing technologies such as high-performance
computing, distributed systems, virtualization, storage, networking, security,
management and automation, SOA, SLA and QoS [12].
2.2 Cloud computing features
Cloud computing provides several features that make it attractive to IT industry,
such as: [4] [15].
No up-front investment: The pricing model in cloud computing is based on a pay-
per-use principle. This model gives the client the ability to rent services and resources
from cloud as he needs.
2015-2016 Page 10
Lowering operating cost: Cloud environment resources are allocated and de-
allocated on demand and this can provide a considerable saving in operating costs
since resources can be released when service demand is low.
Scalability and Elasticity: The infrastructure providers have a large amount of
resources and infrastructure. So they can easily expand its service to handle the
growing service according to client demand. On the other hand, elasticity is the
ability to scale resources both up and down when required. Allowing the dynamic
integration and extraction of physical resources to the infrastructure. That’s mean
elasticity enables scalability.
Easy access: The cloud services provided to users as a web-based services. So, they
can access the services through any devices supported with Internet connections.
Reducing business risks and maintenance expenses: Shifts the business risks such
as hardware failures to infrastructure providers, because providers have better
expertise and resources to manage these risks.
Virtualization: Virtualization hides a computing platform’s physical characteristics
from users; it allows abstraction and isolation of lower level functionalities and
underlying hardware.
Mobility: Cloud Computing means mobility because users can access applications
through internet easily at any point of time.
2.3 Cloud Components
A Cloud system consists of 3 major components such as clients, datacenter, and
distributed servers. Each element has a definite purpose and plays a specific role.
2.3.1 Clients
End users interact with the clients to manage information related to the cloud. Clients
generally fall into three categories as given in [13]:
2015-2016 Page 11
Mobile: Windows Mobile Smartphone, smartphones, like a Blackberry, or an iPhone.
Thin: They don’t do any computation work. They only display the information.
Servers do all the works for them. Thin clients don’t have any internal memory.
Thick: These use different browsers like IE or Mozilla Firefox or Google Chrome to
connect to the Internet cloud.
Now-a-days thin clients are more popular as compared to other clients because of
their low price, security, low consumption of power, less noise, easily replaceable and
repairable etc.
2.3.2 Datacenter
Datacenter is nothing but a collection of servers hosting different applications. An
end user connects to the datacenter to subscribe different applications. A datacenter may
exist at a large distance from the clients. Now-a-days a concept called virtualization is
used to install software that allows multiple instances of virtual server applications.
2.3.3 Distributed Servers
Distributed servers are the parts of a cloud which are present throughout the Internet
hosting different applications. But while using the application from the cloud, the user
will feel that he is using this application from its own machine.
Figure 2-1 three components make up a cloud computing solution
2015-2016 Page 12
2.4 Essential Characteristics of cloud computing
The Essential Characteristics of cloud computing are: [NIST Def]
On-demand self-service: A consumer can unilaterally provision computing
capabilities, such as server time and network storage, as needed automatically without
requiring human interaction with each service provider.
Broad network access: Capabilities are available over the network and accessed
through standard mechanisms that promote use by heterogeneous thin or thick client
platforms (e.g., mobile phones, tablets, laptops, and workstations).
Resource pooling: The provider’s computing resources are pooled to serve multiple
consumers using a multi-tenant model, with different physical and virtual resources
dynamically assigned and reassigned according to consumer demand. There is a sense
of location independence in that the customer generally has no control or knowledge
over the exact location of the provided resources but may be able to specify location
at a higher level of abstraction (e.g., country, state, or datacenter). Examples of
resources include storage, processing, memory, and network bandwidth.
Rapid elasticity: Capabilities can be elastically provisioned and released, in some
cases automatically, to scale rapidly outward and inward commensurate with demand.
To the consumer, the capabilities available for provisioning often appear to be
unlimited and can be appropriated in any quantity at any time.
Measured service. Cloud systems automatically control and optimize resource use
by leveraging a metering capability at some level of abstraction appropriate to the
type of service (e.g., storage, processing, bandwidth, and active user accounts).
Resource usage can be monitored, controlled, and reported.
2015-2016 Page 13
2.5 Cloud Service Model
Cloud Computing can be delivered through such delivery models as follow:
Infrastructure as a Service (IaaS):
This model of Cloud computing provide Hardware as a Service via Internet such as
storage, CPU and other. There are many IaaS providers such as Amazon Elastic Cloud
Compute (EC2), Rackspace [14] [15].
Platform as a Service (PaaS):
Cloud computing provide a platform as a services that required for building
application, where user using tools and libraries for Cloud service providers, and also
consumers deployed their applications without costing of hardware where providers of
services provide the network, storage. There are many PaaS providers such as Google
App Engine, Windows Azure [14] [15].
Software as a Service (SaaS):
Focus on providing different software hosted on the Cloud and usually referred to as
on-demand-software, where in this type of service, consumer will have to pay for usage
of software. Usually consumer access to the software via the Internet, therefore, user uses
the software don’t need any integration with other system [14] [15]. There are many SaaS
provider such as Google Apps, SalesForce.com as shown in Figure2.2 [4].
Figure 2-2 Cloud Computing Architecture
2015-2016 Page 14
2.6 Cloud Deployment Model
Based on the domain or environment in which clouds are used, clouds can be divided
into three types [4] [16]:
Figure 2-3 Types of Clouds
Public clouds:
It’s a cloud in which service providers offer their resources as services to the
general public. Public clouds offer several key benefits to service providers, including
no initial capital investment on infrastructure and shifting of risks to infrastructure
providers. However, public clouds lack fine-grained control over data, network and
security settings, which hampers their effectiveness in many business scenarios.
Private clouds:
Also known as internal clouds, private clouds are designed for exclusive use by a
single organization. A private cloud may be built and managed by the organization or
by external providers. A private cloud offers the highest degree of control over
performance, reliability and security. However, they are often criticized for being
similar to traditional proprietary server farms and do not provide benefits such as no
up-front capital costs.
2015-2016 Page 15
Community clouds:
A community cloud is a collaborative effort in which infrastructure is shared
between several organizations from a specific community with common concerns
(security, compliance, jurisdiction, etc.), whether managed internally or by a third-
party and hosted internally or externally. The costs are spread over fewer users than a
public cloud (but more than a private cloud), so only some of the cost savings
potential of cloud computing are realized.
Hybrid clouds:
A hybrid cloud is a combination of public and private cloud models that tries to
address the limitations of each approach. In a hybrid cloud, part of the service
infrastructure runs in private clouds while the remaining part runs in public clouds.
2.7 Virtualization
Virtualization separates resources and services from the underlying physical
delivery environment [15]. Virtualization is considered as a core of cloud computing
technologies and one of the most important technologies that enabled this paradigm
[16] [17]. Virtualization hides a computing platform’s physical characteristics from
users [16] [17]. It allows abstraction and isolation of lower level functionalities and
underlying hardware. This enables portability of higher level functions and sharing
and/or aggregation of the physical resources [18]. Virtualization means “something
which isn’t real”, but gives all the facilities of a real [6]. It is the software
implementation of a computer which will execute different programs like a real
machine [19]. Virtualization has three characteristics that make it very related with
cloud computing which are [15].
1- Partitioning:
By partitioning the available resources, many applications and operating systems
can run in a single physical system.
2- Isolation:
By isolation, each virtual machine can run in its host with others virtual machine
without effect on others. So, if one virtual instance failed, it doesn’t affect the other
virtual machines.
2015-2016 Page 16
3- Encapsulation:
A virtual machine encapsulated and stored as a single file, so a virtual machine
can be presented to an application as a complete entity without interfere with another
application.
2.8 Conclusion
In this chapter we give an overview about cloud computing. It’s a service oriented
environment. This cloud model is composed of five essential characteristics, three
service models, and four deployment models. We defined the cloud computing and its
characteristics and models. We also defined the virtualization; the key technology in
cloud and presented the benefits of virtualization in cloud computing.
2015-2016 Page 17
Chapter 3
LITERATURE REVIEW
2015-2016 Page 18
3. CHAPTER 3
LITERATURE REVIEW
3.1 Introduction
Resource allocation and load balancing for clouds has been studied very
extensively in the literature. The problem of deciding on an optimal assignment of
requests to resources allocator is NP-hard problem. Several heuristic algorithms have
been proposed by researchers for optimal allocation of cloud resources. ACO is a
heuristic algorithm inspired by the behavior of real ants for solving such problems, which
can be reduced to find good paths through graphs.
This chapter will review different load balancing techniques in cloud computing,
study recent scheduling researches based on ACO and discuses the advantages and
disadvantages of each research.
3.2 Load Balancing in cloud computing environment
It is a process of reassigning the total load to the individual nodes of the
collective system to make resource utilization effective and to improve the response time
of the job, simultaneously removing a condition in which some of the nodes are over
loaded while some others are under loaded. A load balancing algorithm which is dynamic
in nature does not consider the previous state or behavior of the system, that is, it depends
on the present behavior of the system. The important things to consider while developing
such algorithm are : estimation of load, comparison of load, stability of different system,
performance of system, interaction between the nodes, nature of work to be transferred,
selecting of nodes and many other ones. This load considered can be in terms of CPU
load, amount of memory used, delay or Network load.
3.2.1 Goals of Load Balancing in cloud computing
Load balancing in cloud computing provides an efficient solution to various
issues residing in cloud computing environment set-up and usage. Load balancing must
2015-2016 Page 19
take into account two major tasks, one is the resource provisioning or resource allocation
and other is task scheduling in distributed environment. Efficient provisioning of
resources and scheduling of resources as well as tasks will ensure [9].
a. Resources are easily available on demand.
b. Resources are efficiently utilized under condition of high/low load.
c. Energy is saved in case of low load (i.e. when usage of cloud resources is
below certain threshold).
d. Cost of using resources is reduced.
3.2.2 Related work to Load Balancing algorithms
Cloud is made up of massive resources. Management of these resources
requires efficient planning and proper layout. While designing an algorithm for resource
provisioning on cloud the developer must take into consideration different cloud
scenarios and must be aware of the issues that are to be resolved by the proposed
algorithm. Therefore, resource provisioning algorithm can be categorized into different
classes based upon the environment, purpose and technique of proposed solution.
3.2.2.1 Load Balancing on the basis of cloud environment
Cloud computing can have either static or dynamic environment based upon how
developer configures the cloud demanded by the cloud provider.
Static Environment
In static environment the cloud provider installs homogeneous resources. Also the
resources in the cloud are not flexible when environment is made static. In this scenario,
the cloud requires prior knowledge of nodes capacity, processing power, memory,
performance and statistics of user requirements. These user requirements are not
subjected to any change at run-time. Algorithms proposed to achieve load balancing in
static environment cannot adapt to the run time changes in load. Although static
environment is easier to simulate, it is not well suited for heterogeneous cloud
environment.
2015-2016 Page 20
Dynamic Environment
In dynamic environment the cloud provider installs heterogeneous resources. The
resources are flexible in dynamic environment. In this scenario cloud cannot rely on the
prior knowledge whereas it takes into account run-time statistics. The requirements of the
users are granted flexibility (i.e. they may change at run-time). Algorithm proposed to
achieve load balancing in dynamic environment can easily adapt to run time changes in
load. Dynamic environment is difficult to be simulated but is highly adaptable with cloud
computing environment.
3.2.2.2 Load Balancing based on spatial distribution of nodes
Nodes in the cloud are highly distributed. Hence the node that makes the provisioning
decision also governs the category of algorithm to be used. There can be three types of
algorithms that specify which node is responsible for balancing of load in cloud
computing environment.
Centralized Load Balancing
In centralized load balancing technique all the allocation and scheduling decision are
made by a single node. This node is responsible for storing knowledge base of entire
cloud network and can apply static or dynamic approach for load balancing. This
technique reduces the time required to analyze different cloud resources but creates a
great overhead on the centralized node. Also the network is no longer fault tolerant in this
scenario as failure intensity of the overloaded centralized node is high and recovery
might not be easy in case of node failure.
Distributed Load Balancing
In distributed load balancing technique, no single node is responsible for making
resource provisioning or task scheduling decision. There is no single domain responsible
for monitoring the cloud network instead multiple domains monitor the network to make
accurate load balancing decision. Every node in the network maintains local knowledge
base to ensure efficient distribution of tasks in static environment and re-distribution in
dynamic environment.
2015-2016 Page 21
Hierarchical Load Balancing
Hierarchical load balancing involves different levels of the cloud in load balancing
decision. Such load balancing techniques mostly operate in master slave mode. These can
be modeled using tree data structure wherein every node in the tree is balanced under the
supervision of its parent node. Master or manager can use light weight agent process to
get statistics of slave nodes or child nodes. Based upon the information gathered by the
parent node provisioning or scheduling decision is made.
Table 3-1 compares different types of load balancing scenarios in cloud computing
environment.
Type Knowledge Base Issues to be addressed Usage Drawbacks
Static
Prior knowledge base
is required about each
node statistics and
user requirements.
Response time
Resource utilization
Scalability
Power consumption
Makespan
Throughput/Performance
Used in
homogeneous
environment.
Not Flexible
Not scalable
Not compatible
with changing
user requirements
as well as load
Dynamic
Run time statistics of
each node are
monitored to adapt to
changing load
requirements.
Location of processor to
which load is transferred
by an overloaded
processor.
Transfer of task to a
remote machine.
Load estimation.
Limiting the number of
migrations.
Throughput
Used in
heterogeneous
environment.
Complex
Time Consuming
Centralized
Single node or server
is responsible for
maintaining the
statistics of entire
network and updating
it from time to time.
Threshold policies
Throughput
Failure Intensity
Communication between
central server and
processors in network.
Associated Overhead
Useful in small
networks with
low load.
Not fault tolerant
Overloaded
central decision
making node
2015-2016 Page 22
Distributed
All the processors in
the network
responsible
for load balancing
store their own local
database (e.g. MIB) to
make efficient
balancing decisions.
Selection of processor
that take part in load
balancing.
Migration time
Interprocessor
communication
Information exchange
Throughput
Fault tolerance
Useful in large
and
heterogeneous
environment.
Algorithm
complexity
Communication
overhead
Hierarchical
Nodes at different
levels of hierarchy
communicate with the
nodes below them to
get information about
the network
performance.
Threshold policies
Information exchange
criteria Selection of
nodes at different levels
of network Failure
intensity Performance
Migration time
Useful in
medium or
large size
network with
heterogeneous
environment.
Less fault tolerant
Complex
Table 3-1 Load Balancing scenarios comparison
3.3 Literature Review
Now we will study and analyze previous works which have been done for load
balancing in cloud computing using ACO. For each work we will describe the
propose solution, then analyze advantages and disadvantages of this solution.
Ant colony Optimization a Solution of Load balancing in cloud 2012 [20]
Ratan Mishra et al. proposed heuristic algorithm based on ant colony
optimization “MACO” to initiate the service load distribution under cloud computing
architecture. The objective of this paper is to develop an effective load balancing
algorithm using Ant colony optimization technique to maximize or minimize different
performance parameters like CPU load, Memory capacity, Delay or network load for
the clouds of different sizes. Author has discussed how the mobile agents can balance
the load of a cloud using the concept of ACO and proposed an approach for updating
pheromone table. The limitation of this technique is that it will be more efficient if
it’s combined with clustering. Author proposed “Active clustering” technique works
on the principle of grouping similar nodes together and working on these groups.
2015-2016 Page 23
Advantages:
1- The advantage of using MACO is that it is more likely to establish connections
through multiple paths to help balance the load but does not increase the routing
overhead.
2- This modification supports to minimize the make span of the cloud computing
based services (makespan is the time difference between the start and finish of a
sequence of jobs or tasks).
3- Portability of servicing the request also has been converged using the ant colony
optimization technique.
Disadvantages:
1- This technique does not consider the fault tolerance issues.
2- This approach for updating pheromone is only appropriate for routing in
symmetric networks.
3- Less efficient due to the absence of cluster in cloud solution.
4- No simulation or comparison with other algorithms.
Load Balancing of Nodes in Cloud Using Ant Colony Optimization 2012 [21]
Kumar Nishant et al. proposed an efficient algorithm for load balancing of
nodes in cloud environment. The standard ACO algorithm is modified in the way that
ants continue to update a single result set rather than updating their own result set. In
this algorithm a Regional Load Balancing Node (RLBN) is elected to act as a head
node. Other ants consider head node as the root; which means they will update the
single result set obtained from the head node. In this approach, once head node is
elected; doesn’t mean that now it is permanent. Selection can be reset if the past
selection stops functioning efficiently due to some inappropriate conditions.
Advantages:
1- Under loaded node is found at the beginning.
2- New head node can be elected if previous nodes stop functioning properly.
3- The ant updated the single result set rather than updating their own result set.
2015-2016 Page 24
Disadvantages:
1- Network over head due to large number of ants.
2- Points of initiation of ants and number of ants are not clear.
3- Choice of head node is crucial.
4- Nodes status change after ants visit to them is not considered.
5- Only availability of node is being considered, while there are other factors that
should be taken into consideration.
6- Full replication of data.
Effective Scheduling Algorithm for Load balancing using Ant Colony
Optimization in Cloud Computing 2014 [22]
Shagufta Khan et al. proposed and implemented SALB algorithm, an
improvement version of the Ant Colony Optimization. They have modified the
concept of ACO in term of movement of the ant that is in both forward direction and
backward direction and the way in which ants create pheromone table that contains
the information about all nodes and its corresponding load. The goal of this study is to
balance the node with efficiency & maximum utilization of resources. This algorithm
is efficient in finding the overloaded node in minimum time. It also improves the
performance in terms of throughout, response time and energy consumption.
Advantages:
1- Efficient to finding the overloaded node in minimum time
2- Balance the node with efficiency and maximum utilization of resources.
3- Achieve good results in terms of throughout, response time, less energy
consumption.
Disadvantages:
1- better performance is the need of this algorithm by varying different parameters
2- Two types of pheromone.
2015-2016 Page 25
Cloud Task scheduling based on Load Balancing Ant Colony Optimization
2011.[23]
Kun Li et al. proposed the LBACO algorithm (Load Balancing Ant Colony
Optimization) to find the optimal resource allocation for each task in the dynamic
cloud system. The main contribution of this work is to balance the entire system load
while trying to minimize the makespan of a given tasks set. The new scheduling
strategy was simulated using CloudSim toolkit package. Experiments results showed
that proposed LBACO algorithm outperformed FCFS (First Come First Serve) and
the basic ACO.
Advantages:
1- Nodes are balanced dynamically.
Disadvantages:
1- Authors assume that all Tasks are mutually independent, i.e., there is no
precedence constraint between tasks, that’s not general case.
2- They assume that tasks are computationally intensive, which is not realistic for
cloud systems.
3- It doesn’t consider heterogeneity of system
A Load Balancing Mechanism Based on Ant Colony and Complex Network
Theory in Open Cloud Computing Federation 2010 [24]
Zehua Zhang et al. proposed a load balancing mechanism based on ant colony
and complex network theory in open cloud computing federation. An open cloud
computing federation (OCCF) consists of many cloud computing service provider’s
(CCSP) facilities. The proposal mechanism in this paper aims to cope with the
complex and dynamic load balancing problem in OCCF. This mechanism improves
many aspects of the related Ant Colony algorithms which proposed to realize load
balancing in distributed system. The characteristic (small-world and scale-free) of
Complex Network have been taken into consideration.
2015-2016 Page 26
Advantages:
1- Overcome heterogeneous of the cloud computing facilities.
2- Adaptive to the dynamic environments in the OCCF.
3- Excellent in fault tolerance.
4- Good scalability.
Disadvantages:
1- Overhead increases during run time environment.
2- Poor response time.
3- An Ant encounters dead state at the end due to lack of synchronization of
Ants.
Intelligent Strategy of Task Scheduling in Cloud Computing for Load
Balancing- 2013 [25]
Arabi E. keshk et al. proposed MACOLB algorithm (Modified Ant Colony
Optimization for Load Balancing) for cloud task scheduling. They use MACOLB
algorithm to find the optimal resource allocation for tasks in the dynamic cloud
system to minimize the makespan of tasks on the entire system and increase the
performance by balancing the load of the system. The load balancing factor, related to
the job finishing rate, is proposed to make the job finishing rate at different resource
being similar and the ability of the load balancing improved. The proposed
scheduling strategy was simulated using CloudSim. Experimental results showed that
MACOLB algorithm decreases the degree of imbalancing between VMs and
increases the overall performance.
Advantages:
1- MACOLB decreases the degree of imbalancing between available VMs.
2- Increase the overall performance.
Disadvantages:
1- Tasks are mutually independent i.e., there is no precedence constraint between
tasks.
2015-2016 Page 27
Cloud Task Scheduling Based on Ant Colony Optimization 2015 [26]
Medhat Tawfeek et al. proposed cloud task scheduling policy based on ACO for
allocation of incoming jobs to VMs. The main goal of this algorithm is minimizing
the makespan of a given tasks set to help in utilizing the available resources
optimally, minimize the resource consumption and achieve a high user satisfaction.
They compared the proposed approach with different scheduling algorithms; First
Come First Served (FCFS) and Round-Robin (RR). Algorithms have been simulated
using CloudSim toolkit package. Experimental results showed that cloud task
scheduling based on ACO outperformed FCFS and RR algorithms.
Advantages:
1- Considerable reduction in task completion time.
2- Dynamic task allocation.
Disadvantages:
1- Tasks are mutually independent.
2- Tasks are not preemptive and they cannot be interrupted or moved to another
processor during their execution.
3- The same resource and VM would be over utilized, since ants would converge to
first available position.
ACO-LB Algorithm for Task Scheduling in the Cloud Environment 2014 [27]
Shengjun Xue et al. proposed a ACO-LB (Load balancing optimization algorithm
based on ACO) to solve the load imbalance of VMs in the process of task scheduling.
ACO-LB will not only shorten the makespan of task scheduling, but also maintain the
load balance of VMs in the data center. This work considered dependent tasks and
workflow model with priority constraints using DAG (Directed Acyclic Graph). This
algorithm can adapt to the dynamic cloud environment. ACO-LB has been simulated
in CloudSim and the results show that it can efficiently provide appropriate resources
for tasks and improve the utilization rate of resources.
2015-2016 Page 28
Advantages:
1- ACO-LB algorithm has better performance and load balancing ability.
2- ACO-LB considers the dependency between tasks.
Disadvantages:
1- This paper only presents one workflow model with single structure and
correlation to verify the advantages of the ACO-LB algorithm.
2- This paper only considers minimizing the execution time of tasks and ignores the
cost problem existing in reality.
A New Approach to Ant Colony to Load Balancing in Cloud Computing
Environment 2015 [28]
Hamid Mehdi proposed a modification for ACO. The main aim of the proposed
algorithm is efficient in finding the overloaded node and load balancing in lowest
time. The proposed method associated with concept of ACO promotion in connection
with movement of the ant which is in both forward and backward direction. The ant
use two types of pheromone for its movement these are:
Foraging Pheromone (FP) - Generally ACO uses foraging pheromones to
explore new food sources. In this algorithm the ant would lay down foraging
pheromone after encountering under loaded nodes to search overloaded nodes.
Trailing Pheromone (TP) - In a typical ACO the ant uses trailing pheromone
to discover its path back to the nest. However, in this algorithm the ants would
use this to find its path to the under loaded node after encountering overloaded
Node.
The aim is to balance the node with efficiency & maximum utilization of
resource. The algorithm is simulated in CloudSim. The results show that the proposed
algorithm improves the performance in terms of throughout, response time.
Advantages:
1- Ant moves in both directions.
2- Achieve efficiency & maximum utilization of resources.
2015-2016 Page 29
Disadvantages:
1- More storage required for pheromone.
2- This algorithm didn’t consider the energy related issues.
Balancing throughput and response time in online scientific Clouds via Ant
Colony Optimization 2015 [29]
Elina Pacini et al. described and evaluated a Cloud scheduler based on ACO.
The goal of this work is to study private Clouds to execute scientific experiments
coming from multiple users. This work focuses on IaaS model where custom VM are
launched in appropriate hosts available in a Cloud. In this scheduler, the load is
calculated on each host taking into account the CPU utilization made by all the VMs
that are executing on each host. The main performance metrics are the number of
serviced users by the cloud, the total number of created VMs in online (non-batch)
scheduling scenarios and the number of intra-cloud network messages sent. Simulated
experiments performed using CloudSim and job data from real scientific problems
show that proposed scheduler succeeds in balancing the studied metrics compared to
schedulers based on Random assignment and Genetic Algorithms.
Advantages:
1- Describe a two-level Cloud scheduler.
2- Address an online Cloud scenario.
3- Balancing the number of serviced users in a cloud and the total number of created
VMs.
4- Use an exponential back-off strategy to retry allocating failing VMs.
Disadvantages:
1- High network consumption.
2- This work didn’t consider heterogeneous physical resources.
3- The algorithm didn’t consider Energy consumption.
2015-2016 Page 30
Energy Efficient Allocation of Virtual Machines in Cloud Data Centers 2010 [30]
Anton Beloglazov and Rajkumar Buyya proposed an efficient resource
management policy for virtualized Cloud data centers to minimize energy
consumption, while providing reliable QoS. The heuristic approach presented in this
paper use technique derived, from the Best Fit Decreasing algorithm. The goal is to
place each migrating VM on the server that minimizes the overall power consumption
of the data center. They also proposed and evaluated heuristics for dynamic
reallocation of VMs. The obtained results show that the technique of dynamic
reallocation of VMs and switching off the idle servers brings substantial energy
savings and is applicable to real-world Cloud data centers.
Advantages:
1- Reducing energy consumption.
2- Handling QoS requirements.
3- Considering heterogeneous infrastructure and heterogeneous VMs.
4- They do not depend on a particular type of workload and do not require any
knowledge about applications executing on VMs.
Disadvantages:
1- This is deterministic and centralized algorithm whose efficiency deteriorates as
the size of the data center grows and suffers from scalability and fault tolerance
issues.
2- mapping strategies may require the concurrent migration of many VMs, which
can cause considerable performance degradation during the reassignment process
3- Consider only CPU utilization as a resource for reallocation decisions.
Energy-Aware Ant Colony Based Workload Placement in Clouds 2011 [31]
In this work Eugen Feller et al. modeled the VM allocation problem as an
instance of the multidimensional bin-packing (MDBP) problem considering many
resources (i.e., CPU cycles, CPU cores, RAM size, network bandwidth and disk size).
They presented workload resource demand estimation approach to minimize the
2015-2016 Page 31
amount of performance degradation and designed a novel, nature-inspired workload
consolidation algorithm based on ACO to compute the placement dynamically
according to the current load. In order to improve the performance a multithreaded
version of the ACO-based workload consolidation algorithm was developed. The
ultimate goal of this work is to minimize the amount of hosts, thus increasing the
average utilization of each host. The proposed algorithm was evaluated by comparing
it with one frequently applied greedy algorithm (i.e., FFD). Simulation results
demonstrated that ACO outperforms the evaluated greedy algorithm as it achieves
superior energy gains through better server utilization and requires fewer machines.
Moreover, it computes solutions which are nearly optimal.
Advantages:
1- This was the first work to apply ACO on the MDBP and consider many resources.
2- Minimize the number of machines.
Disadvantages:
1- They assume a homogeneous environment in which all physical machines have
the same capacity.
2- The algorithm requires the prior knowledge about all the workload.
3- This approach is also implemented in a centralized manner.
4- Maximum energy gain is 5.88%.
5- They didn’t consider QoS and risk of SLA violation.
Energy Aware Virtual Machine Placement scheduling in Cloud Computing
Based on Ant Colony Optimization Approach 2014 [32]
Xiao-Fang Liu et al. proposed an approach based on ACO to solve the Virtual
Machine Placement Problem (VMP), named as ACO-VMP, so as to effectively use
the physical resources and to reduce the number of running physical servers. The
number of physical servers is the same as the number of the VMs at the beginning.
Then the ACO approach tries to reduce the physical server one by one. Experimental
results compared with the ones obtained by the first-fit decreasing (FFD) algorithm
2015-2016 Page 32
show that ACO-VMP can solve VMP more efficiently to reduce the number of
physical servers significantly, especially when the number of VMs is large.
Advantages:
1- Reduce Energy consumption by reducing the number of physical servers.
Disadvantages:
1- All servers are homogeneous.
2- They only consider CPU and memory resources.
3- They didn’t consider the QoS for customers.
Energy-efficient virtual machine placement in data centers with heterogeneous
requirements 2014 [33]
Xiangming Dai et al. focused in this paper on reducing the power consumption
of data centers in public cloud environments by exploring two greedy approximation
algorithms: the minimum power VM placement algorithm (MinPow); that attempts to
decrease the power consumption by avoiding powering up unnecessarily additional
servers and the minimum communication virtual machine placement algorithm (Min
Com); that aims at packing one user's VMs as much as possible on the same server or
under the same rack to decrease the networking energy cost. The performance of
these two algorithms has been evaluated and compared to other alternatives in both
small scale and large scale clusters. Results showed that MinPow and MinCom yield
placements that are within 5% to 10% energy consumption of the optimal solution.
Advantages:
1- Heterogeneous Environment.
2- They consider power consumed by Network Devices in large scale Data Center.
3- The proposed Algorithms are near to optimal solution.
Disadvantages:
1- Central algorithm.
2- Proposed algorithms are designed only to reduce energy while they ignore the
effects on QoS for customers.
2015-2016 Page 33
An Energy Efficient Virtual Machine Consolidation in Cloud Computing 2015
[34]
Jayshri Damodar Pagare et al. proposed a VMs consolidation approach to
consider the trade-off between energy consumption and performance. The most
important contributions of this paper are as follows: 1) Proposing an efficient
algorithm which finds and decides overloaded host with SLA violation 2) Proposing
an efficient algorithm for finding underutilized hosts. 3) Combine two proposed
algorithms as VM consolidation algorithm to get better results in both power
consumption and SLA violation. The overload detection finds overloaded host and
get the status of it whether it result in SLA Violation or not. If there is no SLA
violation then no migration required which saves power required to migrate VMs. But
if there is SLA violation then place all the VMs from this host to other hosts until the
host becomes under load. Proposed algorithms have been implemented and evaluated
using CloudSim simulator. Simulation results showed improvement in energy
consumption.
Advantages:
1- The algorithm reduces SLA violation and energy consumption.
2- It reduces number of migrations by trigger migration only if overload host
generates SLA violation host.
3- This work considers heterogeneous environment.
Disadvantages:
1- They concentrate on rebalancing the load but they didn’t mention the initial
allocation algorithm.
2- Long execution time.
Power Efficient Resource Allocation for Clouds Using Ant Colony Framework
2011 [35]
Lskrao Chimakurthi et al. presented an energy efficient mechanism for adaptive
resource allocation in cloud computing environments for hosting the applications with
given QoS requirements as throughput and response time. This algorithm reduces the
2015-2016 Page 34
power consumption of data center resources by considering the dynamic loads of
servers using different ant agents.
Advantages:
1- It’s very flexible mechanism that can be extended with improvements
2- It considers dynamic loads of servers.
Disadvantages:
1- There are many types of agents.
2- They didn’t evaluate the proposed mechanism.
3- They didn’t include the load prediction and usage models so this mechanism can’t
be applied to real cloud environments.
An ACO-based Scheduling Strategy on Load Balancing in Cloud Computing
Environment 2015 [36]
Wei-Tao Wen et al. proposed ACO-VMM; a novel distributed VM migration
strategy based on ACO. In ACO-VMM Strategy, local migration agent autonomously
monitors the resource utilization and launches the migration. At monitoring stage, it
takes both the previous and current system condition into account to avoid
unnecessary migrations. Besides, it adopts two different traversing strategies for ants,
Positive and Negative Traversing, in order to find the near-optimal mapping
relationship between VMs and PMs. The proposed strategy is evaluated by using
CloudSim. Experimental results showed that ACO-VMM achieves load balancing
and reasonable resource utilization, which outperforms the existing migration
strategies in terms of number of VM migrations and number of SLA violations.
Advantages:
1- This algorithm reduces number of migrations.
2- It takes the memory utilization and the bandwidth condition into account.
3- High reliability and scalability.
4- It considers heterogeneous Environment.
Disadvantages:
1- Threshold has a fixed value.
2015-2016 Page 35
3.4 Conclusion
After the literature review, we came to conclude that scheduling and load
balancing is challenging task in cloud computing and it’s very important research area
now-a-days. Many of the existing approaches nowadays still ignore the
multidimensional character of the problem. Also, many researches adopted VM
allocation strategy in centralized manner. However, one of the main limitations of all
current cloud management frameworks next to their high degree of centralization is
that they do not provide any advanced energy-aware workload consolidation policies.
Energy consumption has become substantial issues in cloud computing recently and it
should be considered in load balancing. Only some algorithms consider energy
consumption during solving the load balancing problem; the main idea of these
algorithms is to set upper and lower utilization thresholds and keep the total CPU
utilization of a node between them by using Live Migration. However, Most
researches set static threshold, which is not suitable for heterogeneous environment
and dynamic load.
2015-2016 Page 36
Chapter 4
METHODOLOGY AND PROPOSED ALGORITHM
2015-2016 Page 37
4. CHAPTER 4
METHODOLOGY AND PROPOSED ALGORITHM
4.1 Introduction
Swarm Intelligence techniques are increasingly used to solve optimization
problems, and thus they result good alternatives to achieve the goals proposed in this
work. SI is a discipline that deals with natural and artificial systems composed of many
individuals that coordinate themselves using decentralized control and self-organization.
Examples of systems that studied by SI are ants’ colonies. The advantage of these
techniques derives from their ability to explore solutions in large search spaces in a very
efficient way along with little initial information. Moreover, using SI techniques is an
interesting approach to cope in practice with the NP-completeness of job scheduling. In
this chapter we will explain briefly the methods used in this work; ACO then we will
apply this method to solve the VM allocation problem. Besides that, to ensure QoS for
customers, proposed adaptive threshold using IQR method which will be shown later on
in this chapter. Finally, the complete algorithm will be presented including pseudo code
and data flow diagram.
4.2 Ant Colony Optimization algorithm
Ant Colony Optimization “ACO” is one example of SI techniques. It is a meta-
heuristic algorithm with efficient local search for combinatorial problems. It’s a general
framework that can be used to create a specific algorithm to solve a specific graph path
problem. ACO imitates the behavior of real ant colonies in nature to search for food and
to connect to each other by pheromone laid on paths traveled. Many researches use ACO
to solve NP-hard problems such as traveling salesman problem, graph coloring problem,
vehicle routing problem, and so on. Although ACO was proposed in a 1992 doctoral
thesis by M. Dorigo, the first detailed description of the algorithm is generally attributed
to a 1996 follow-up paper by M. Dorigo, V. Maniezzo and A. Colorni. Since then, ACO
has been widely studied and modified.
2015-2016 Page 38
4.2.1 Ant In Nature
Ant Colony Optimization (ACO) [29, 30] is a meta-heuristic inspired by the
observation of real ant colonies and based upon their collective foraging behavior [26].
Ants are social insects and live in colonies. Their behavior is governed by the goal of
colony survival. When searching for food, ants frequently travel between their nest and
food sources. At the beginning, ants explore the area surrounding their nest in a random
manner. While moving, ants deposit special substances called pheromones along their
paths. Ants can smell pheromones. When choosing their way, they tend to choose, in
probability, paths marked by strong pheromone concentrations. As soon as an ant finds a
food source, it evaluates the quantity and the quality of the food and carries some of it
back to the nest. During the return trip, the quantity of pheromones that an ant leaves on
the ground may depend on the quantity and quality of the food. The pheromone trails will
guide other ants to the food source. However, if over time ants do not visit a certain path,
pheromone trails start to evaporate, thus reducing their attractive strength. The more the
time an ant needs to travel down the path and back again, the less the pheromone trails
are reinforced. The indirect communication between the ants via pheromone trails
enables them to find the shortest paths between their nest and food sources. From an
algorithmic point of view, the pheromone evaporation process is useful for avoiding the
convergence to a local optimum solution.
Fig. 4-1 shows two possible paths from the nest to the food source, but one of them is
longer than the other one. Fig. 4-1(a) shows how ants will start moving randomly at the
beginning to explore the ground and then choose one of two paths. The ants that follow
the shorter path will naturally reach the food source before the others ants, and in doing
so the former group of ants will leave behind them a pheromone trail. After reaching the
food, the ants will turn back and try to find the nest. Moreover, the ants that perform the
round trip faster strengthen more quickly the quantity of pheromone in the shorter path,
as shown in Fig. 4-1(b). The ants that reach the food source through the slower path will
find attractive to return to the nest using the shortest path. Eventually, most ants will
choose the left path as shown in Fig.4-1(c).
2015-2016 Page 39
Figure 4-1 Adaptive behavior of ants
4.2.2 Ant Colony Optimization
The above behavior of real ants has inspired ACO. One of its main ideas is exploiting
the indirect communication among the individuals of an ant colony. ACO employs
pheromone trails as a kind of distributed numerical information which is modified by ants
to reflect their accumulated experience while solving a particular problem. At each
execution step, ants compute a set of feasible moves and select the best one (according to
some probabilistic rules) to carry out all the tour. The transition probability for moving
from a place to another is based on the heuristic information and pheromone trail level of
the move. The higher the value of the pheromone and the heuristic information, the more
profitable it is to select this move and resume the search.
4.2.3 Basic Steps for ACO
Algorithm: Basic Steps for ACO
1. Initialize the pheromone
2. While criteria not satisfied, then repeat
3. Initially set locations of all ants on an entry state
4. Selection of next state
5. While not reached to the final state then repeat from step 4, if reached then Step 6.
6. Pheromone stages (deposit, daemon and evaporate pheromone)
7. Check whether criteria satisfied or not, if satisfied then end, if not then repeat from
step 2.
8. End.
2015-2016 Page 40
Figure 4-2 Flowchart of ant colony optimization
4.2.4 Advantages and disadvantages of ACO
4.2.4.1 ACO Advantages
1- Inherent Parallelism.
2- Used in dynamic application.
3- Positive feedback leads to rapid discovery of good solutions.
4- Distributed computation avoids premature convergence.
5- The greedy heuristic helps find acceptable solution in the early solution in the early
stages of the search process.
6- The collective interaction of a population of agents.
4.2.4.2 ACO Disadvantages
1- Theoretical analysis is difficult.
2- Sequence of random decision (not independent).
3- Probability distribution changes by iteration.
4- Research is experimental rather than theoretical.
5- Time of convergence uncertain.
2015-2016 Page 41
4.3 The Bin Packing Problem
Definition: Given a list of objects and their weights, and a collection of bins of
fixed size, find the smallest number of bins so that all of the objects are assigned to a bin.
Bin packing is an NP-hard combinatorial optimization problem, based on the partition
problem. Finding the optimal solution is known to be exponentially difficult. One
solution methodology is to formulate the problem as an integer programming problem.
The run-time performance of traditional exact methods, such as branch and bound,
degrade as the problem size increases, however. In order to handle larger problems,
heuristic methods have been developed. Some of the more popular algorithms are given
in the following discussion.
Next Fit Heuristic (BP-NF). Place the items in the order in which they arrive. Place
the next item into the current bin if it fits. If it does not, close that bin and start a new
bin.
Example:
Given the set of items S = {4, 8, 5, 1, 7, 6, 1, 4, 2, 2} and bins of size 10, pack the
items into as few bins as possible using Next Fit. The results of using the Next fit
algorithm are shown in the figure below.
Figure 4-3 Packing under Next Fit
First Fit Heuristic (BP-FF). Place the items in the order in which they arrive. Place
the next item into the lowest numbered bin in which it fits. If it does not fit into any
open bin, start a new bin.
Example:
Given the set of items S = {4, 8, 5, 7, 6, 1, 4, 2, 2, 1} and bins of size 10, pack the
items into as few bins as possible using First Fit. The solution is shown here.
2015-2016 Page 42
Figure 4-4 Packing under First Fit
Best Fit Heuristic (BP-BF): The general idea is to obtain the best global packing by
getting the best local packing of individual bins. Place the items in the order in which
they arrive. Place the next item into that bin which will leave the least room left over
after the item is placed in the bin. If it does not fit in any bin, start a new bin.
Example:
Given the set of items S = {4, 8, 5, 1, 7, 6, 1, 4, 2, 2} and bins of size 10, pack the
items into as few bins as possible using Best Fit.
Figure 4-5 Packing under Best Fit
In this example, it turns out that the packings for BP-FF and BP-BF are the same.
Worst Fit Heuristic (BP-WF): Place the items in the order in which they arrive.
Place the next item into that bin which will leave the most room left over after the
item is placed in the bin. If it does not fit in any bin, start a new bin.
Example:
Given the set of items S = {4, 8, 5, 1, 7, 6, 1, 4, 2, 2} and bins of size 10, pack the
items into as few bins as possible using Worst Fit.
Figure 4-6 Packing under Worst Fit
2015-2016 Page 43
4.4 Proposed Energy Efficiency VM allocation based on ACO
To find the optimal solution of a VM allocation problem is NP-hard [Jung et al.,
2010], therefore it is interesting to use heuristics instead of calculating the exact solution,
for efficiency reasons, since a slow algorithm would not be interesting in real data centers
receiving several requests to allocate new VMs at every second. To efficiently and
dynamically manage the VM resources, in this section, we first present VM allocation
problem. Then the problem is formulated as a combinatorial optimization problem
(COP). After that we come up with the solution for this problem using ACO based
approach to reduce Energy consumption while providing desirable QoS for customers.
The motivation of using ACO is that the VMP is formulated as a COP while ACO has
been widely accepted as a promising approach to solve various COPs.
ACO algorithm can be applied to any combinatorial problem as far as it is possible to
define:
1. Problem representation represents the problem as a graph which allows ants to
incrementally build/ modify solutions.
2. A constraint satisfaction method which forces the construction of feasible
solutions.
3. The heuristic desirability η of edges.
4. A pheromone updating rule which specifies how to modify pheromone trail τ
on the edges of the graph.
5. A probabilistic transition rule of the heuristic desirability and of pheromone
trail.
4.4.1 Problem Representation
A cloud data center consists of a large number of heterogeneous PMs with
different resource capacities. At any given time, a cloud data center usually serves many
simultaneous users and as a result, VMs with different resource capacities are created on
PMs. Several VMs may be deployed into a PM, and the number of the VMs in each PM
can be different from each other. However, an VM can be allocated to only one PM.
2015-2016 Page 44
Let:
P = {P1, P2, . . . , PM} be the set of all the PMs in a data center, where M is the
number of PMs and Pj, ∀j = 1, . . . , M represents the j-th PM.
V = {V1, V2, . . . , VN} be the set of all the virtual machines in a data center,
where N is the number of VMs and Vi, ∀i= 1, . . . , N represents the i-th VM.
The problem is represented as a graph G= (K, E) where the set of nodes K
represents the PMs and VMs and the set of edges E the connections between the host and
VM as shown in Figure 4-3. All ants are placed at the starting Hosts randomly. During an
iteration ants build solutions to the VM allocation problem by moving from one host to
another until they complete a tour (all VMs have been allocated). Each ant represents one
VM. Iterations are indexed by t, 1< t < tmax, where tmax is the maximum number of
iterations allowed.
Figure 4-7 Problem representation of VM Allocation
2015-2016 Page 45
4.4.2 System models and problem formulation
In a cloud environment, we have a pool of server nodes with applications running
on them. Suppose that the cluster is fully virtualized and all the applications are running
on VMs. The problem of VM placement across a pool of server nodes is related to the
multidimensional vector packing problems. Dimensions in the packing problem are
resource utilizations. For simplicity, we consider CPU and Memory resources. If two
VMs are running on the same server, the CPU and Memory utilization of the server is
estimated as the sum of the CPU and Memory utilizations of the two VMs For example,
let (25%, 30%) be a CPU and memory request of one VM, and (35%, 40%) be that of
another VM, the utilizations of a server accommodating the two VMs are estimated at
(60%, 70%). To prevent CPU usage of a server from reaching 100%, we have to impose
an upper bound on resource utilization of a single server with some threshold value. The
main idea behind this is that 100% utilization can cause severe performance degradation
and VM live migration technology consumes some amount of CPU processing capability
on the migrating node.
4.4.2.1 Resource utilization model
Resources of physical server are consumed by VMs which are allocated on this
server. So, we can represent the resource utilization as sum of the resource demand of all
VMs allocated to this server.
𝑈𝑐𝑗 = (𝑥𝑖𝑗
𝑛
𝑖=1
.𝑉𝑐𝑖) 4.1
𝑈𝑚𝑗 = (𝑥𝑖𝑗
𝑛
𝑖=1
.𝑉𝑚𝑖 ) 4.2
When 𝑉𝑐𝑖 and 𝑉𝑚𝑖 are CPU and memory demand of VMi (1≤i≤N). xij is binary variable
indicates if VMi is assigned to server j or not. 𝑈𝑐𝑗 and 𝑈𝑚𝑗 represent the current CPU
and Memory utilization of server j.
2015-2016 Page 46
4.4.2.2 Power consumption model
The power consumed by a physical server comes from CPU, memory and storage
systems. Recent studies show that the power consumption of servers can be accurately
described by a linear relationship between the power consumption and CPU utilization.
In order to save energy, servers are turned off when they are idle. Hence, their idle power
is not part of the total energy consumption. Finally, we defined the power consumption of
the jth
server as a function of the CPU utilization as shown in Eq. 4.3.
𝑝𝑗𝑖𝑑𝑙𝑒 + 𝑝𝑗
𝑏𝑢𝑠𝑦− 𝑝𝑗
𝑖𝑑𝑙𝑒 × 𝑈𝐶𝑗 ,𝑈𝑐𝑗 >0 4.3
0 otherwise
Where Pidle is the power consumed by an idle server, Pbusy is the power consumed by
a fully loaded server. Ucj represent the CPU utilization of server j. Real data shows that
typically Pidle is around 0.6 x Pbusy, and is hardly lower than 0.5 x Pbusy.
4.4.2.3 Problem formulation
Next, we formalize the VM placement optimization problem, suppose that we are
given N VMs (applications) i ∈ I that are to be placed on M servers j ∈ J. For simplicity,
we consider only CPU and memory resources. Each physical server j (1≤j≤M) has CPU
capacity 𝑝𝑐𝑖 and memory capacity 𝑝𝑚𝑖 . Let Tc j, Tm j be the threshold of CPU and
memory utilization associated with jth
server respectively. 𝑈𝑐𝑗 and 𝑈𝑚𝑗 represent the
CPU and memory that have been used by all the VMs deposited on server j. We use two
binary variables xij and yj. The binary variable xij indicates if VMi is assigned to server j
and the binary variable yj indicates whether server j is in use (yj=1) or not (yj=0). The goal
is to find the allocations of the VMs on physical servers such that the power consumed by
all the equipments is minimized and resources are highly utilized. We assume that none
of the VMs requires more resources than can be provided by a single server. The
placement problem can therefore be formulated as:
Pj =
2015-2016 Page 47
The objective function:
𝑀𝑖𝑛𝑖𝑚𝑖𝑧𝑒 𝑝 = 𝑝𝑗 = [𝑦𝑗𝑚𝑗=1
𝑀𝑗=1 × 𝑝𝑗
𝑏𝑢𝑠𝑦− 𝑝𝑗
𝑖𝑑𝑙𝑒 × 𝑈𝑐𝑗 + 𝑝𝑗𝑖𝑑𝑙𝑒 ] 4.4
Where p is the total power consumed by all servers included in the solution. Eq. 4.4
means the less power consumed, the solution is better.
Constraints:
Subject To:
𝑥𝑖𝑗
𝑚
𝑖=1
= 1 ∀ 𝑖 ∈ 𝐼 4.5
𝑥𝑖𝑗 ≤ 𝑦𝑗 ∀ 𝑖 ∈ 𝐼, 𝑗 ∈ 𝐽 4.6
𝑈𝑐𝑗 ≤ 𝑇𝑐𝑗 ∀ 𝑗 ∈ 𝐽 4.7
𝑈𝑚𝑗 ≤ 𝑇𝑚𝑗 ∀ 𝑗 ∈ 𝐽 4.8
𝑦𝑗 , 𝑥𝑖𝑗 ∈ [0,1] ∀ 𝑖 ∈ 𝐼, 𝑗 ∈ 𝐽 4.9
Constraint (4.5) assigns a VMi to one and only one of the servers. Constraint (4.6) if any
VMi is allocated to a server j, then the status of the server j must be on. Constraints (4.7)
and (4.8) model the capacity constraint of the server. Constraint (4.9) defines the domain
of the variables of the problem.
Given a set of N VMs and a set of M PMs, there are a total of M N possible VM
placement solutions. It is therefore typically impractical to make a complete enumeration
of all possible solutions to find the best solutions. The following shows how to apply an
ACO algorithm to efficiently search for good solutions in large solution spaces.
4.4.3 The description of the proposed ant colony algorithm
All ACO algorithms adapt the algorithm scheme explained next. After initializing the
pheromone trails and control parameters, a main loop is repeated until a stopping
criterion is met (e.g., a certain number of iterations to perform or a given time limit
without improving the result). In this loop, ants construct feasible solutions and update
the associated pheromone trails. Furthermore, partial problem solutions are seen as nodes
2015-2016 Page 48
(an abstraction for the location of an ant); each ant starts to travel from a random node
and moves from a node i to another node j of the partial solution. At each step, the ant k
computes a set of feasible solutions to its current node and moves according to a
probability distribution.
4.4.3.1 Probabilistic Decision Rule
For an ant k the probability pk
ij to move from a node i to a node j is:
Where:
Ƞij is the attractiveness of the move as computed by some heuristic information
indicating a prior desirability of that move.
Ʈij is the pheromone trail level of the move, indicating how profitable it has been in
the past to make that particular move (it represents therefore a posterior indication
of the desirability of that move).
𝛼 and 𝛽 are two parameters which determine the relative influence of the
pheromone trail and the heuristic information, The role of the parameters 𝛼 and 𝛽
is the following. If 𝛼 = 0, the heuristic is used for selection. If 𝛽 = 0, only
pheromone trial is at work.
allowed k is the set of active servers that still have sufficient resources to host VMi
𝑎𝑙𝑙𝑜𝑤𝑒𝑑 𝐾 =
𝑗 (( 𝑥𝑗𝑘 .𝑉𝑐𝑘 + 𝑉𝑐𝑖) ≤ 𝑇𝑐𝑗 ) ^ 𝑖−1𝑘=1
(( 𝑥𝑗𝑘 .𝑉𝑚𝑘 + 𝑉𝑚𝑖) ≤ 𝑇𝑚𝑗 )𝑖−1𝑘=1
𝑦𝑗 = 1,∀ 𝑗
4.11
4.10
2015-2016 Page 49
The higher the pheromone value and the heuristic information, the more profitable it is to
include j in the partial solution.
The initial pheromone level is a positive integer Ʈ0. In nature, there is not any pheromone
on the ground at the beginning (i.e., Ʈ0 =0). However, the ACO algorithm requires Ʈ0 > 0,
otherwise the probability to chose the next state would be pkij = 0 and the search process
would stop from the beginning.
An ant selects a server according to the rule as follow:
𝑗 = arg𝑚𝑎𝑥𝑠 ∈𝑎𝑙𝑙𝑜𝑤𝑒𝑑𝐾
𝑝𝑖𝑗𝑘
𝑖𝑓𝑞 ≤ 𝑞0
𝐽, 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
4.12
When q0 (0≤q0≤1) is a parameter, q (0≤q≤1) is a random number. 𝑎𝑙𝑙𝑜𝑤𝑒𝑑𝐾 is the set
of servers that still have sufficient resources to host VMi. J is a random number selected
according to probability distribution calculated by Eq. 4.10 above. This selection way can
increase the randomness to avoid local optimum.
4.4.3.2 Heuristic Information
The heuristic information is important in the solution construction. It represents
the desirability to assign VMi to server j. Good heuristic information guides the ants to
move targeted. It’s related to the improvement that VMi can contribute to improve the
objective function by selecting the server j that will be utilized the most by placing the
VM in it to achieve higher resource utilization and as a result reduce number of physical
servers and reduce energy consumption. We should mention here that we already
consider the QoS by assign upper threshold and keep utilization under this threshold.
Mathematically; the heuristic information of placing VMi on Sj can be calculated as:
𝜂 𝑖, 𝑗 =
1
𝑇𝐶𝑗−(𝑈𝐶𝑗+ 𝑉𝑐𝑖 ) + 𝑇𝑚 𝑗−(𝑈𝑚 𝑗+ 𝑉𝑚𝑖 ) 𝑖𝑓 𝑆𝑗 ∈ 𝑎𝑙𝑙𝑜𝑤𝑒𝑑 𝑘 4.13
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
Where Tcj and Tmj represent the CPU and memory upper threshold of server Si. Uci
and Umi represent the CPU and memory that has been used of Server j. 𝑉𝑐𝑖 and 𝑉𝑚𝑖
represent CPU and memory demands of current VM.
2015-2016 Page 50
4.4.3.3 Pheromone trail update
The ants communicate indirectly through the pheromone information. One may
consider. There are two different pheromone structures: one that associates a pheromone
trail with every movement VM-Server, or one that associates a pheromone trail with
every pair of VMs. In this work, the first way of laying pheromone trails is used, i.e., the
pheromone trail τ i j will be defined as the favorability of packing VMi into Server j.
The pheromone update comprises local update and global update. Local pheromone
update is followed by an ant that has finished building its solution, the local pheromone is
update as:
𝜏 𝑖, 𝑗 = 1 − 𝜌 . 𝜏 𝑖, 𝑗 + 𝜌. 𝜏0 4.14
The global pheromone updating is applied after the best current solution is found. It
increases the pheromone value on hosts in the best solution. In this way, the algorithm
can converge faster. The pheromone deployed on Sj in the current best solution is
updated as:
𝜏 𝑖, 𝑗 = (1 − 𝜀). 𝜏 𝑖, 𝑗 + 𝜀.∆𝜏(𝑖, 𝑗) 4.15
Where:
∆𝜏(𝑖, 𝑗) Represents additional added pheromone
∆𝜏 𝑖, 𝑗 =1
𝑃(𝑠) 4.16
Where P(s) is the normalized power consumption of the solution S. and its value is
calculated according to the following equation:
𝑃 𝑠 = 𝑃𝑗
𝑝𝑗max
𝑀𝑗=1 4.17
Normally, the quantity of the added pheromone depends on the quality of the solution.
2015-2016 Page 51
4.4.4 Interquartile Range (IQR) method for finding dynamic threshold
The interquartile range (IQR) is a measure of statistical dispersion of data and an
estimate of variability, based on dividing a data set into quartiles. It is also called as
middle fifty and midspered. It is the difference between the upper and lower quartile in a
data set.
In this work; to find utilization upper threshold, we will use historical data from the
resource usage by VMs For decision making about when a host must be considered as an
overloaded host and We use Interquartile Range (IQR) method to design an adaptive
utilization threshold method.
IQR=Q3 - Q1 4.18
Where Q1 and Q3 are the 25th
percentile and 75th
percentile respectively of a sorted
set. Then the upper threshold for host Hi is found by Eq. 4.19.
UpTht=1 – sp. IQR 4.19
Where sp ∈ R+ is a parameter of the method that defines how aggressively the
system consolidates VMs is. In other words, the parameter sp allows the adjustment
of the safety of the method, the lower sp, the less the energy consumption, but the
higher the level of SLA violations caused by the allocation. Here value for sp is 1.5.
Steps for finding Interquartile Range based threshold:
1. Sort the data set in increasing order.
2. Find the median for the ordered set.
3. Divide the data set into two halves.
4. Find the median for the first half of the ordered data set (Lower Quartile Q1).
5. Find the median for the second half of the ordered data set (Upper Quartile Q3).
6. IQR = Upper Quartile – Lower Quartile.
7. UpTht=1 – sp. IQR
Here data set defines set of the host utilization.
2015-2016 Page 52
Example:
Let us assume the utilization of each host (in terms of percentage).
List of host utilization [70,62,64,72,63,64,81,77,81,76]
1. After sorting [62 , 63 , 64 , 64 , 70 , 72 , 76 , 77 , 81 , 81]
2. Median = (70+72) / 2 =71
3. First half [62 , 63 , 64 , 64 , 70], Second half [72 , 76 , 77 , 81 , 81]
4. Median of the first half =64, which is Q1.
5. Median of Second half = 77, which is Q2.
6. IQR= 77 – 64 = 13
7. UpThr= 1 – 1.5 (0.77-0.64) = 1 – 0.195 = 0.805 = 80.5 %
Figure 4-8 Interquartile Range Threshold
4.4.5 The complete proposed algorithm
In Algorithm.1 each ant works independently and tries to find best allocation for
VMs with regarding to energy consumption. Each ant constructs a solution Sk and after
find the solution, it will update the local pheromone. When all ants finish, their solutions
will be evaluated to find the best solution. Evaluation will be according to number of
active servers and energy consumption; the less the servers used and the less the energy
consumed, the better solution. Then, apply global pheromone update to the servers of best
solution. Repeat this procedure while stop criteria is not reached; here stop criteria is
equal to max number of iterations. Every iteration finds a best solution and compares
with previous best solution. Finally, after NI; number of iterations, the algorithm returns
the best solution which represents the best VMs allocation.
2015-2016 Page 53
Algorithm 1. ACO-based Allocation Algorithm
Input: Hosts : List of servers with capacity constraint
VMs : List of VMs with resource demand
Set of parameters.
Output: VM Allocation
/*Initialization*/
1. Set the value of the parameters
2. Initialize all the pheromone values of all hosts to Ʈ0
/*Iterative Loop*/
3. For n= 1 to NI (number of iterations) do
4. For K=1 to Nant (number of ants) do
/* Construct a solution */
5. Sk=AntK.constructSolution(VMs, Hosts)
6. Local pheromone updating
7. End For /* number of ants */
/* Evaluation */
8. Evaluate each solution Sk by calculating objective function value
9. Select the best solution /* which consume less energy */
10. Global pheromone update
11. End For /*number of iteration */
12. Return bestSolution
Algorithm.2 shows how an ant constructs a solution. Each ant starts with a set of
servers including one random server at the beginning. An ant allocates virtual machines
one by one to this server while it is suitable for resource requirements. If not, turn on a
new server and allocate the VM on it. A server is suitable for VM if it has a free amount
of processing power and memory under threshold greater than or equal to that of required
by the unallocated VM. If the active server set Sk contains more than one server that are
suitable for VM then the ant choose the server with highest defined probability and
allocate VM to it.
2015-2016 Page 54
Algorithm 2. constructSolution
Input: Hosts : List of servers with capacity constraint
VMs : List of VMs with resource demand
Output: Solution Sk
1. Mk=0 /*number of active servers in solution*/
2. Initialize set of active servers Sk =∅
3. Select a server t randomly and add to Sk
4. Mk =1, Sk = Sk ∪ 𝐭
5. For i = 1 to NVM (number of VMs) do
6. allocatedServer=NULL
/* choose server to allocate VMj */
7. Generate random variable q 𝛜 [𝟎,𝟏]
8. If q ≤ q0 then
/* choose the server according to probability Eq. 4.10 */
9. allocatedServer=chooseServerForVM (vmi,Mk)
10. Else
/*choose the server according to Eq. 4.12*/
11. allocatedServer=chooseServerRandomly(vmi,Mk)
12. End if
/*if no server is Sk can allocate VMi, add a server t from
nonactive servers which has minimum resources */
13. If allocatedServer =NULL
14. t = addNewServer();
15. Sk = Sk ∪ 𝐭 /*add the server to active servers set*/
16. Mk = Mk +1
17. allocatedServer = t
18. End if
19. End For /* number of VMs */
20. Return Sk
2015-2016 Page 55
Algorithm.3 shows how an ant chooses host for VM, an ant calculates the
probability for all suitable servers according to Eq. 4.10; the server is suitable if it has
enough resources for VM under threshold (Eq. 4.11). The probability composed of
heuristic and pheromone. This algorithm uses the Best Fit heuristic; which will choose
the highest utilized server which can allocate VM. The idea behind using this heuristic is
using resources of active servers efficiently by keeping active servers more utilized and
allocate more VMs to active server as it’s possible and maybe we can reduce the number
of active servers by turn off low loaded servers after completion their assigned VMs or
by migrating VMs from low loaded servers to another active server. However, the QoS is
considered through upper threshold. Assigning upper threshold ensures that resource
utilization will not reach to 100%.
Algorithm 3. chooseServerForVM
Input: VMi with resources demands and set of active servers in current solution Sk
Output: Server allocated to VM
1. bestServer=NULL
2. bestProbability=0
3. For each server j ∈ Sk do
4. j.upperThreshold=CalculateUpperThreshold (j,sp);
5. If j is suitable for VMi
6. Calculate heuristic value 𝜼 𝒊, 𝒋 for allocation Vmi to j according to Eq.4.13
7. Calculate probability value pij for allocation Vmi to j according to Eq.4.10
8. If pij> bestProbability then
9. bestProbability = pij
10. bestServer = j
11. End if
12. End if
13. End For
14. Return bestServer
2015-2016 Page 56
Algorithm.4 shows how to calculate upper threshold dynamically using utilization
history information and IQR method.
Algorithm 4. CalculateUpperThreshold
Input: Server j and safety parameter sp
Output: Adaptive UpperThreshold
1. list utilizationData = gethostutilizationHistory(j)
2. sort_ ascend (utilizationData)
3. getMedian (utilizationData)
4. divide utilizationData according to Median (d1,d2)
5. Q1= getMedian(d1)
6. Q2= getMedian(d2)
7. Calculate IQR= Q3-Q1
8. threshold=1-sp.IQR
9. Return threshold
2015-2016 Page 57
Figure 4-9 Data Flow Diagram for proposed algorithm
2015-2016 Page 58
4.5 Conclusion
ACO is a heuristic algorithm with efficient local search for combinatorial problems.
ACO imitates the behavior of real ant colonies in nature to search for food and to connect
to each other by pheromone laid on paths traveled. Many researches use ACO to solve
NP-hard problems such as traveling salesman problem, graph coloring problem, vehicle
routing problem, and so on. In this chapter VM allocation problem has been presented
and formulated as combinatorial problem and ACO based algorithm has been proposed to
solve this problem. Proposed algorithm used Best Fit heuristic to select the proper server
for VM and achieve high resource utilization. To avoid utilization from reaching 100%
and ensure QoS for customers, IQR method has been used to obtain upper threshold
dynamically using utilization history. This algorithm consume resources efficiently and
reduce energy while guarantees QoS for customers. In next chapter, the proposed
algorithm will be evaluated using CloudSim, the most used cloud simulator in cloud
computing researches.
2015-2016 Page 59
Chapter 5
SIMULATION AND EXPERIMENTAL RESULTS
2015-2016 Page 60
5. CHAPTER 5
SIMULATION AND EXPERIMENTAL RESULTS
5.1 Introduction
As the targeted system is an IaaS in cloud computing, it’s better to evaluate the
proposed algorithm on a large-scale virtualized data center infrastructure. But Real
hardware for experimental evaluation is not always available to researchers and it’s very
difficult to conduct repeatable large-scale experiments on a real infrastructure, which is
required to evaluate and compare the proposed algorithm. Therefore, to ensure the
repeatability of the experiments, simulations have been chosen as a suitable way to
evaluate the performance of the proposed algorithm. For testing the effectiveness of a
particular policy that is to be implemented on a cloud we need a simulation framework
that can provide an environment that is close to the actual cloud, and can generate results
that can help in the analysis of the policies so that we can deploy them on actual Clouds.
Some energy-aware simulation packages are GreenCloud, MDCSim, CloudSim and
GSSIM. Among the available packages, CloudSim has been the most widely used by
scholars. For our experiments, the CloudSim toolkit has been chosen as a simulation
framework. The toolkit has been developed by the Cloud Computing and Distributed
Systems (CLOUDS) Laboratory, University of Melbourne. It supports both system and
behavior modeling of cloud system components such as data centers, virtual machines
and resource provisioning policies. Currently, it supports modeling and simulation of
cloud computing environments consisting of both single and inter-networked clouds
(federation of clouds), and also supports energy-efficient management of datacenter
resources. Apart from the energy consumption modeling and accounting, the ability to
simulate service applications with dynamic workloads has been incorporated. The major
limitation of CloudSim is the lack of a graphical user interface (GUI). But despite this,
CloudSim is still used in universities and the industry for the simulation of cloud-based
algorithms.
2015-2016 Page 61
5.2 Simulation Environment - CloudSim
CloudSim is a self-contained platform which can be used to model data centers, host,
service brokers, scheduling and allocation policies of a large scaled Cloud platform. This
CloudSim framework is built on top of GridSim framework which is also developed by
the GRIDS laboratory. Hence, the researcher has used CloudSim to model datacenters,
hosts, VMs for experimenting in simulated cloud environment [32]. In this project work
CloudSim version 3.0 is used to test and analyze allocation policies.
5.2.1 CloudSim Characteristics
CloudSim can be used to model datacenters, host, VMs, service brokers, and
scheduling and allocation policies of a large scaled cloud platform. Cloud supports VM
provisioning at two levels:
1. At the host level: It is possible to specify how much of the overall processing
power of each core will be assigned to each VM known as VM policy Allocation.
2. At the VM level: The VM assigns a fixed amount of the available processing
power to the individual application services (task units) that are hosted within its
execution engine known as VM Scheduling [9].
In this project, the ACO algorithm will be used for VM allocation to Hosts at the host
level.
5.2.2 The CloudSim Platform
The main entities of CloudSim and the relationship between them are shown in
Figure 5-1.
CIS (Cloud Information Service): It is an entity that registers data center
entity and discovers the resource.
Data Center: It models the core infrastructure-level services (hardware),
which is offered by cloud providers. It encapsulates a set of compute hosts
that can either be homogeneous or heterogeneous.
2015-2016 Page 62
Data Center Broker: It models a broker, which is responsible for mediating
negotiations between SaaS and cloud providers.
VM Allocation: A provisioning policy which is run in data center level helps
to allocate VMs to hosts.
VM Scheduler: This is an abstract class implemented by a host component
that models the policies (space-shared, time-shared) required for allocating
processor cores to VMs. It is run on every host in data center.
Host: It models a physical server.
VM: It models a VM which is run on cloud host to deal with the cloudlet.
Cloudlet: It models the cloud-based application services.
Cloudlet Scheduler: This abstract class is extended by the implementation of
different policies that determine the share (space-shared, time-shared) of
processing power among cloudlets in a VM [33].
Figure 5-1 Main Entities of CloudSim
CloudSim work style is shown as Figure 5-2. In general, the tasks from different users
are relatively independent; we consider there are m users, as User1, User2, ……Userm, n
independent tasks, as T1, T2 …Tn, n Virtual Machines, as VM1, VM2 ……VMn and p
datacenters, as Datacenter1, Datacenter2 … Datacenterp.
2015-2016 Page 63
Figure 5-2 CloudSim Work Style
5.2.3 CloudSim Data Flow
Each datacenter entity registers with the Cloud Information Service registry (CIS).
CIS provides database level match-making services; it maps user requests to suitable
cloud providers. The DataCenterBroker consults the CIS service to obtain the list of
cloud providers who can offer infrastructure services that match application’s quality of
service, hardware, and software requirements. In the case match occurs the broker
deploys the application with the cloud that was suggested by the CIS [33]. CloudSim data
flow is shown in Figure 5-3.
Figure 5-3 CloudSim data flow
2015-2016 Page 64
5.3 Simulation steps
CloudSim project follows some standard steps to implement the specified
configuration to start a simulation. There are eleven steps that are followed in each
simulation with some variation in them, specified as follows:
1- Set Number of users for current simulation. This user count is directly
proportional to number of brokers in current simulation.
2- Initialize the simulation, provided with current time, number of users and trace
flag.
3- Create a Data center(s).
4- Create a Data center broker.
5- Create a Virtual Machine(s).
6- Submit Virtual Machine to Data center broker.
7- Create Cloudlet(s) by specifying there characteristics.
8- Submit Cloudlets to Data center broker.
9- Send call to Start Simulation.
10- Once no more event to execute, send call to Stop Simulation.
11- Finally print the final status of the Simulation.
VM Allocation policy is invoked by Data center broker after submission the
VM’s (step 6). In this project we need to create a new VM Allocation policy in power
module to simulate power aware VM allocation using Ant Colony Optimization.
5.4 Simulation Classes
In Simulation we create and update the following java classes:
1- RandomConstants.java: to specify number of Hosts and VMs, we have done
number of experiments by change these parameters to show the change of
objectives, metrics when No. of VMs is increased with same No. of Hosts.
2- RandomHelper.java: it creates cloudlets list according to dynamic workload.
3- Helper.java: creates VM’s list, Hosts’ list, DataCenter and DataCenterBroker.
First, DataCenter has to be created, and then it creates list of hosts in the
2015-2016 Page 65
datacenter. After that, DataCenterBroker has to be created; the interface between
customer and cloud DataCenter, and submit VMs’ requests to DataCenterBroker
who will allocate them to physical hosts. Also this class calculates the objective
metrics such as SLA and energy.
4- RandomConstants.java: it includes Hosts and VM’s characteristics. In this work
we consider heterogeneous environment, so there are two types of hosts with
different resources and four types of VMs with different requirements.
5- PowerVmAllocationPolicyMigrationAbstract.java: we change this class to
implement our VM allocation algorithm based on ACO.
6- RandomRunner.java: it defines simulation characteristics and initializes
simulation.
7- ant_colony.java: it defines parameters of Ant Colony algorithm.
8- Ant.java: it’s the main class which initializes simulation characteristics and create
instance of RandomRunner.java to start simulation.
5.5 Simulation Settings
For performing experiments physical machine has a 2.53 GHz Intel(R) core(TM) i3
processor, 4GB RAM, 640 GB hard disk, and 64-bit Operating System Windows 7
Professional. In our experiment latest version of CloudSim toolkit, CloudSim 3.0.3 was
used for modeling and simulation of cloud computing environments and evaluation of
proposed algorithm.
The experiments are done in heterogeneous environment, where there are two types
of hosts and four types of VMs with different characteristics (Table 5.3) and dynamic
load for tasks. The environment consists of a Datacenter with M Hosts and N number of
VMs requests. Number of Hosts is fixed to 100 Hosts and we will change the number of
VMs. Each experiment has been repeated ten times to take average.
To evaluate proposed algorithm, we will compare with the algorithm proposed in [8]
according to some metrics.
2015-2016 Page 66
5.3.1 System Mode
In this work, it is assumed that each CPU has c cores and each core has m MIPS, so
total MIPS of a CPU is c × m. Two servers are used in this work: HP ProLiant ML110
G4, HP ProLiant ML110 G5. In the following we show the configuration and power
consumption, respectively.
Table 5-1 configuration of servers
Table 5-2 Power consumption of server at different load levels in watts
The reason why we have not chosen servers with more cores is that it is important to
simulate a large number of servers to evaluate the effect of VM consolidation. Thus,
simulating less powerful CPUs is advantageous, as less workload is required to overload
a server. Nevertheless, dual-core CPUs are sufficient to evaluate resource management
algorithms designed for multi-core CPU architectures.
5.3.2 Workload Data
To make a simulation based evaluation applicable, it is important to conduct
experiments using workload traces from a real system. In CloudSim we use data provided
as a part of the CoMon project, a monitoring infrastructure for PlanetLab. The input will
consist of the data on the CPU utilization by more than a thousand VMs from servers
located at more than 500 places around the world. The interval of utilization
measurements is 5 minutes and each traced file have 288 lines, therefore, each one
represent VMs CPU utilization about 24 hours.
2015-2016 Page 67
5.3.3 Simulation parameters
The parameters settings of cloud simulator are shown in next table.
Entity Type parameters Value
Data Center
system architecture x86
operating system Linux
Hypervisor Xen
Time zone 10.0
cost 3.0
costPerMem 0.05
costPerStorage 0.001
costPerBw 0.0
Host
Types 2
RAM 4096 MB
Storage 40 GB
Number of Processing Entities 2
MIPS rating of Processing Entity 1860, 2660
Bandwidth 1 Gbit/s
VM
Types 4
RAM 128, 256, 512, 1024
Image size (Storage) 2.5 GB
Number of Required PEs 1
MIPS rating 250, 500, 750, 1000
Bandwidth 100 Mbit/s
VM Monitor Xen
cloudlet Input File Size 300
Output File Size 300
Table 5-3 Simulation parameters
2015-2016 Page 68
5.3 Evaluation and experimental results
5.3.1 Number of Active Hosts
More physical servers means more energy consumption and more money cost. In
practice, powering-up a physical server without any CPU load, consumes more than 60%
of the energy consumed by a server with a fully loaded CPU. From power consumption
model in Eq. 4.3 we can see that power consumption is directly and linearly related to
resource utilization and number of active hosts. Therefore, an energy efficient VM
placement aims to reduce the number of active physical machines, by increasing the
workload in the current active machines, which decreases the energy consumption.
No. of VMs 25 50 75 100 125 150 200
Existing Algorithm 25 50 75 100 100 100 100
Proposed Algorithm 3 7 10 15 18 22 25
Table 5-4 Number of Active Hosts
Figure 5-4 Number of Active Hosts
0
10
20
30
40
50
60
70
80
90
100
110
0 25 50 75 100 125 150 200
No
. of
Act
ive
Ho
sts
No. of VMs
No. of Active Hosts
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 69
In this experiment, number of Hosts is fixed to 100 hosts and number of VMs is
varying between 0 and 200 with step=25 to see the effect of number of VM requests
before reaching to max number of hosts and after.
Table 5-4 shows the number of active hosts in based algorithm and proposed one.
Based algorithm allocates VM to less loaded host, then each VM request will be allocated
to a new host while there are free hosts. Otherwise, if all hosts are active and have work,
allocation will be to less loaded active host. We can see that number of active Hosts
increases linearly with number of VM requests up to max number of available hosts.
Whereas, in our proposed algorithm, we will exploit running machine and place as many
VMs as it can satisfy the resource requirements. If not, add a new physical machine and
place the VM on this new machine. New host will added only when it’s required and
there is no any host able to allocate the VM request. On average, each host can allocate 8
VMs with given hosts and VM characteristics in table 5-3. From Figure 5-4, we can see
that the difference in number of active hosts become larger when VM requests increased
and energy will increase.
5.3.2 Energy Consumption
We consider the total energy consumption of the physical resources in a data center
that is required to handle the application workloads. The energy consumption of a PM
depends on the utilization of its CPU, memory, disk, and network card. Most studies [35]
show that CPU consumes more power than memory, disk storage, and network interface.
Therefore, the resource utilization of a PM is usually represented by its CPU utilization
as shown in Eq.4.3. Instead of using an analytical model of energy consumption, we used
the real data in the SPECpower benchmark.1 Table 5-2 illustrates the amount of energy
consumption of HP G4 and G5 servers at different load levels.
In this experiment, number of Hosts is fixed to 100 hosts and number of VMs is
varying between 0 and 200 with step=100. Table 5-5 shows the energy consumption by
data center measured by KwH. We can see that existing algorithm [8] will consume more
than 60% of Max power for first 100 VMs only! That’s because the algorithm allocate
VM to less loaded host and as a result during allocation first 100 VMs all hosts will be
2015-2016 Page 70
active and table 5-2 shows that each server consumes more than 60% even if it doesn’t do
any work. After first 100 VMs energy consumption will be linear. Proposed algorithm
will consume energy almost linearly with number of VMs. The gain is highest when
number of VMs equal to number of hosts because at this time all hosts will be active in
existing algorithm while only about 15 hosts will be active in proposed algorithm (as
shown by table 5-4). When number of VMs reaches near maximum the difference in
energy consumption will decrease because almost most of hosts will be high loaded up to
max.
No. of VMs 100 200 300 400 500
Existing Algorithm 89.14 97.45 109.12 128.01 149.88
Proposed Algorithm 19.185 43.08 67.395 92.32 119.405
Table 5-5 Energy Consumption
Figure 5-5 Energy Consumption
0
10
20
30
40
50
60
70
80
90
100
110
120
130
140
150
160
0 100 200 300 400 500
Ener
gy K
wH
No of VMs
Energy Consumption
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 71
5.3.3 Quality of Service
Meeting QoS requirements is very important for Cloud computing. QoS requirements
are commonly formalized as SLAs, which can be determined in terms of characteristics
such as minimum throughput, maximum response time or minimum bandwidth and so
on. These characteristics are workload or application dependent. However, the algorithm
framework belongs to IaaS layer in cloud computing and should be workload
independent. Beloglazov and Buyya proposed a useful a metric called SLAV (SLA
Violation) to evaluate the SLA delivered by a VM in an IaaS cloud.
SLA violations can be encountered due to non-availability of resources, higher
network load, and system failure. When we talk about the SLA violations in energy
efficient environment; it is mainly due to workload consolidation on minimum number of
servers. In such scenario, servers are fully utilized to minimize the overall energy
consumption. However, whenever the VM’s demand for resources increases, we may
encounter an SLA violation due to non-availability of required resources at the current
physical machine. So, when proposing energy-efficient VMs allocation, one needs to be
aware of the SLA to avoid performance degradation of the consumer applications,
including increased response times, timeouts or even failures and cloud providers have to
establish QoS requirements to avoid SLA violations and deal with the energy-
performance trade-off meeting the QoS requirements while minimizing energy
consumption. The objective is to minimize power consumption and maximize SLA.
Therefore, in order to increase the QoS for the end-Users then minimize this SLA from
getting violated. In this work, we proposed adaptive upper threshold to avoid utilization
from reaching to 100% and decrease SLA violation as a result. To evaluate the proposed
algorithm, overall and average SLA Violation will be used as metrics and the results will
be compared with existing algorithm in [8].
SLA model can either be defined as fully allocating the requested amount of
resources or allowing flexible resource allocations up to a specific rate as long as the
agreed SLA can be delivered (e.g. allowing the CPU share to be 10% below the requested
amount). CloudSim supports modeling of the aforementioned SLA violation scenarios.
2015-2016 Page 72
Moreover, it is possible to define particular SLA-aware policies describing how the
available capacity is distributed among competing VMs in case of a lack of resources.
The number of SLA violation events as well as the amount of resource that was requested
but not allocated can be accounted for by CloudSim. We consider SLA violation as the
difference between requested MIPS and allocated MIPS. Overall SLA violation is
defined as shown in Eq. 5.1:
𝑂𝑣𝑒𝑟𝑎𝑙𝑙𝑆𝐿𝐴𝑉 = (𝑟𝑒𝑞𝑢𝑒𝑠𝑡𝑒𝑑 𝑀𝐼𝑃𝑆) − (𝑎𝑙𝑙𝑜𝑐𝑎𝑡𝑒𝑑 𝑀𝐼𝑃𝑆) / 𝑟𝑒𝑞𝑢𝑒𝑠𝑡𝑒𝑑 𝑀𝐼𝑃𝑆 5.1
Table 5-6 and Figure 5-6 show average SLA violation which is calculated by taking mean
for SLA violation of all hosts. We can see that SLA Violation decreases comparing to
existing algorithm. The main idea behind SLA improvement is assigning upper threshold
to avoid 100% utilization.
No. of VMs 100 200 300 400 500
Existing Algorithm 11.12% 11.73% 12.70% 13.83% 13.88%
Proposed Algorithm 9.62% 10.06% 10.69% 10.97% 12.09%
Table 5-6 Average SLA Violation * 100
Figure 5-6 Average SLA Violation * 100
0.00%
2.00%
4.00%
6.00%
8.00%
10.00%
12.00%
14.00%
16.00%
18.00%
20.00%
100 200 300 400 500
Ave
rage
SLA
Vio
lati
on
* 1
00
No. of VM
Average SLA Violation * 100
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 73
Table 5-7 and Figure 5-7 show overall SLA violation which is calculated by Eq. 5.2. We
can see also it decrease with comparing to base algorithm. Although, the improvement is
small; at least we improved SLA beside reduce energy consumption.
No. of VMs 100 200 300 400 500
Existing Algorithm 1.09% 1.20% 1.68% 1.97% 2.01%
Proposed Algorithm 0.57% 1.05% 1.37% 1.55% 1.74%
Table 5-7 Overall SLA Violation * 100
Figure 5-7 Overall SLA Violation * 100
5.3.4 Energy and SLA Violations (ESV)
The main metrics are energy consumption by physical nodes and SLAV; however,
these metrics are typically negatively correlated as energy can usually be decreased by
the cost of the increased level of SLA violations. The objective of the proposed VM
Allocation approach is to minimize both energy and SLA violations. Since there is a
trade-off between performance and energy consumption, we measured a combined metric
0.00%
0.50%
1.00%
1.50%
2.00%
2.50%
100 200 300 400 500
Ove
all S
LA V
iola
tio
n
No. of VM
Overall SLA Violation * 100
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 74
called Energy and SLA Violations that captures both the Energy Consumption and the
SLA Violations as:
𝐸𝑆𝑉 = 𝐸 . 𝑆𝐿𝐴𝑉 5.2
Table 5-8 shows results of Energy and SLA violation metric; we consider overall SLA
violation. Figure 5-8 shows the comparison between base algorithm and proposed one
with regarding to ESV metric; we can see clearly that proposed algorithm overperforme
the base algorithm because proposed algorithm reduces both of energy and SLA violation
in same time.
No. of VMs 100 200 300 400 500
Existing Algorithm 0.971626 1.1694 1.833216 2.521797 3.012588
Proposed Algorithm 0.109355 0.45234 0.923312 1.43096 2.077647
Table 5-8 Energy and SLA Violations
Figure 5-8 Energy and SLA Violations
0
0.5
1
1.5
2
2.5
3
3.5
100 200 300 400 500
ESV
No. of VMs
ESV
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 75
5.3.5 Execution Time
Execution time is another important metric to evaluate algorithms. Proposed
algorithm decrease execution time by checking only active servers to allocate VM and
only if no active server can allocate VM then add new server. Base algorithm also tried to
decrease time by allocating VM directly to server if its load equal to zero, but after
allocating first 100 VMs all servers have to be checked. Table 5-9 shows execution time
for base and proposed algorithms.
In this experiment, we fixed number of hosts to 100 and change number of VMs between
0 and 50 by step 10. Figure 5-9 shows the comparison between base and proposed
algorithms.
No. of VMs 100 200 300 400 500
Existing Algorithm 9.1 19.78 25.34 30.51 42.11
Proposed Algorithm 4.24 7.26 13.83 16.59 18.49
Table 5-9 Excution Time
Figure 5-9 Excution Time
0
10
20
30
40
50
0 10 20 30 40 50
Tim
e (
ms)
No. of VM
Execution Time
Based ACO
Proposed ACO
Total 100 Hosts
2015-2016 Page 76
5.4 Conclusion
The proposed algorithm has been implemented and evaluated using CloudSim; the
most used simulator in cloud computing researches. Simulation has been done by using
workload traces from a real system and power consumption information from real
servers. Experimental results shows that proposed algorithm led to significantly less SLA
violations than base algorithm which has been presented in [8]. The main reason is that
proposed algorithm assign threshold to avoid load from reaching 100% percent and this
threshold is calculated dynamically using load history information. Proposed algorithm
also use less number of servers and consumes less power; our proposed VM allocation
approach reduces energy consumption by up to 60% percent when number of VM
requests is small with comparing to number of hosts. Also regarding execution time,
proposed algorithm reduces it by include active servers only in search space.
2015-2016 Page 77
Chapter 6
CONCLUSION AND FUTURE WORK
2015-2016 Page 78
6. CHAPTER 6
CONCLUSION AND FUTURE WORK
6.1 Conclusion
In the last years cloud computing has become more and more popular. This increase
in popularity of cloud services results in higher resource demands on the providers end.
More resources mean more energy consumption and thus higher electricity bills. For this
reason, energy-efficient management of data center resources is an important problem for
environmental (CO2 emissions) and financial reasons. On the other hand, it is essential
for Cloud providers to offer reliable QoS for the customers that are negotiated in terms of
SLA, such as minimal throughput and maximal response time or latency of the system.
Therefore, the main challenge is to reduce energy consumption of data centers while
satisfying QoS requirements.
In this project VM allocation problem has been formulated as optimization problem
with function objective to reduce energy consumption. ACO based algorithm has been
proposed to solve this problem. Proposed algorithm used Best Fit heuristic to select the
proper server with the highest load to use resource efficiently. To avoid utilization from
reaching 100% and ensure QoS for customers, dynamic upper threshold has been
proposed using IQR method. We consider two resources, CPU and memory. The
simulation has been done using CloudSim with heterogeneous environment including two
types of servers and four types of VMs, workload traces from a real system and power
consumption information from real servers. Evaluation has been done using five metrics;
energy consumption, QoS in term of SLA, ESV (energy and SLA violation for trade-off),
number of active servers and execution time. Experimental results showed that our
algorithm outperformed the base algorithm which has been proposed in [8]. Our proposed
VM allocation approach reduces energy consumption by up to 60% percent. It led to
2015-2016 Page 79
significantly less SLA violations. This algorithm consume resources efficiently and
reduce energy while guarantees QoS for customers.
6.2 Future Work
In order to evaluate the proposed system in a real Cloud infrastructure, we plan to
implement it by extending a real world Cloud platform, such as OpenStack. Another
direction for future research is the investigation of more complex load and power models
considering more system resource, such as network interface and disk storage, as these
resources also significantly contribute to the overall energy consumption. Furthermore,
we would like to introduce more intelligent techniques to improve QoS. Besides, we plan
to further improve the proposed system model by clustering PMs and assigning them to
the respective managers. We also look forward to combine some other heuristic methods
with ACO; there are lots of algorithms which have been proved work well with ACO
algorithm like genetic algorithm.
2015-2016 Page 80
7. REFERENCES
1. Florence, A.P. and Shanthi, V., Intelligent Dynamic Load Balancing Approach
for Computational Cloud. International Journal of Computer Applications: pp. 15-18, (2013).
2. Sharma, T. and Banga, V.K., Efficient and Enhanced Algorithm in Cloud
Computing. International Journal of Soft Computing and Engineering (IJSCE), (March 2013).
3. R. Brown et al., “Report to congress on server and data center energy
efficiency: Public law 109-431,” Lawrence Berkeley National Laboratory, 2008. 4. Zhang, Q., Cheng, L., and Boutaba, R., Cloud computing: state-of-the-art and
research challenges. Journal of Internet Services and Applications, pp. 7-18, (2010).
5. Singh, A., Gupta, S., and Bedi, R., Comparative Analysis of Proposed
Algorithm With Existing Load Balancing Scheduling Algorithms In Cloud
Computing. International Journal of Emerging Trends & Technology in Computer Science (IJETTCS), pp. 197-200, (2014).
6. Tiwari, M., Gautam, K., and Katare, K., Analysis of Public Cloud Load
Balancing using Partitioning Method and Game Theory. International Journal of Advanced Research in Computer Science and Software Engineering, pp. 807-812, (2014).
7. Ratan, M. and Anant, J., Ant colony Optimization: A Solution of Load
Balancing in Cloud. International Journal of Web & Semantic Technology (IJWesT), (2012).
8. Elina Pacini, Cristian Mateos, and Carlos García Garino. Balancing throughput
and response time in online scientific Clouds via Ant Colony
Optimization. Adv. Eng. Softw. 84, C (June 2015), 31-47. 9. Reena Panwar, A Comparative Study of Various Load Balancing
Techniques in Cloud Computing. International Journal of Engineering Research & Technology (ijert), Vol. 3 - Issue 9 (September - 2014).
10. Martin Randles, David Lamb, A. Taleb-Bendiab, A Comparative Study into Distributed Load Balancing Algorithms for Cloud Computing, 2010 IEEE 24th International Conference on Advanced Information Networking and Applications Workshops.
11. Kaleeswari and Juliet, N., Dynamic Resource Allocation by Using Elastic
Compute Cloud Service.International Journal of Innovative Research in Science, Engineering and Technology (IJIRSET), pp. 12375-12379,(2014).
2015-2016 Page 81
12. Jararweh, Y., Alshara, Z., Jarrah, M., Kharbutli, M., and Alsaleh, M.N. TeachCloud: A CloudComputing Educational Toolkit. The 1st International IBM Cloud Academy Conference. North Carolina, USA, pp. 1-16, (2012).
13. Anthony T.Velte, Toby J.Velte, Robert Elsenpeter, Cloud Computing A Practical
Approach, TATA McGRAW-HILL Edition 2010.
14. Khatib, V. and Khatibi, E. Issues on Cloud Computing: A Systematic Review. International Conference on Computational Techniques and Mobile Computing.
Singapore, (2012).
15. Sareen, P., Cloud Computing: Types, Architecture, Applications, Concerns,
Virtualization and Role of IT Governance in Cloud. International Journal of Advanced Research in Computer Science and Software Engineering, pp. 533-538, (2013).
16. Sajid, M. and Raza, Z. Cloud Computing: Issues & Challenges.International Conference on Cloud. pp. 35-41, (2013).
17. Marisol, G.-V., Cucinotta, T., and Lu, C., Challenges in real-time virtualization
and predictable cloud computing. Journal of Systems Architecture (ELSEVIER): pp. 1-15, (2014).
18. Vouk, M.A., Cloud Computing – Issues, Research and Implementations.
Journal of Computing and Information Technology - CIT: pp. 235-246, (2008). 19. 21. Padhy, R.P. and Rao, G.P., Load Balancing in Cloud Computing Systems:
Orissa, India, (2011). 20. Ratan Mishra, Anant Jaiswal, Ant colony Optimization: A Solution of Load
balancing in Cloud, International Journal of Web & Semantic Technology (IJWesT) Vol.3, No.2, April 2012.
21. Kumar Nishant, Pratik Sharma, Vishal Krishna, Chavvi Gupta Kuwar Pratap Singh, Nitin and Ravi Rastogi, “Load Balancing of Nodes in Cloud Using Ant Colony
Optimization,” in proc. 14th International Conference on Modelling and Simulation, IEEE, pp. 3-8, July 2012.
22. Shagufta Khan, Niresh Sharma, “Effective Scheduling Algorithm for Load
balancing using Ant Colony Optimization in Cloud Computing”,
International Journal of Advanced Research in Computer Science and Software Engineering, Volume 4, Issue 2, February 2014.
23. Kun Li; Gaochao Xu; Guangyu Zhao; Yushuang Dong; Wang, D., "Cloud Task Scheduling Based on Load Balancing Ant Colony Optimization," in Chinagrid Conference (ChinaGrid), 2011 Sixth Annual , vol., no., pp.3-9, 22-23 Aug. 2011
24. Zehua Zhang; Xuejie Zhang, "A load balancing mechanism based on ant colony and complex network theory in open cloud computing federation," in Industrial Mechatronics and Automation (ICIMA), 2010 2nd International Conference on , vol.2, no., pp.240-243, 30-31 May 2010
25. Arabi E. keshk, Ashraf El-Sisi, Medhat A. Tawfeek, F. A. Torkey, “Intelligent Strategy of Task Scheduling in Cloud Computing for Load Balancing”.in International Journal of Emerging Trends & Technology in Computer Science (IJETTCS), Volume 2, Issue 6, November – December 2013.
2015-2016 Page 82
26. Medhat Tawfeek, Ashraf El-Sisi, Arabi Keshk and Fawzy Torkey, “Cloud Task Scheduling Based on Ant Colony Optimization”, in The International Arab Journal of Information Technology, Vol. 12, No. 2, March 2015.
27. Shengjun Xue, Mengying Li, Xiaolong Xu, Jingyi Chen, “An ACO-LB Algorithm for Task Scheduling in the Cloud Environment”, in Journal of Software, Vol 9, No 2 (2014), 466-473, Feb 2014.
28. Hamid Mehdi, A New Approach to Ant Colony to Load Balancing in Cloud Computing Environment” in International journal of Computer Science & Network Solutions (ijcsns) , Volume 3.No.5. ISSN 2345-3397, May 2015.
29. Elina Pacini, Cristian Mateos, Carlos Garcia Garino, “Balancing throughput and response time in online scientific Clouds via Ant Colony Optimization”, Advances in Engineering Software, Vol 84 , Pages 31–47 ,June(2015)
30. Anton Beloglazov and Rajkumar Buyya, “Energy Efficient Allocation of Virtual Machines in Cloud Data Centers”, 10th IEEE/ACM International Conference on Cluster, Cloud and Grid Computing, 2010
31. Eugen Feller, Louis Rilling, Christine Morin, “Energy-Aware Ant Colony Based Workload Placement in Clouds” , [Research Report] RR-7622, INRIA. 2011.
32. Xiao-Fang Liu, Zhi-Hui Zhan (Corresponding Author), Ke-Jing Du, Wei-Neng Chen, “Energy Aware Virtual Machine Placement Scheduling in Cloud Computing Based on Ant Colony Optimization Approach”, Proceedings of the 2014 Annual Conference on Genetic and Evolutionary Computation, Pages 41-48, 2014.
33. Xiangming Dai, Jason Min Wang, Brahim Bensaou, “Energy-efficient virtual machine placement in data centers with heterogeneous requirements”, Cloud Networking (CloudNet), 2014 IEEE 3rd International Conference on,Pages:161-166, 2014.
34. Jayshri Damodar Pagare, Dr. Nitin A Koli, “An Energy Efficient Virtual Machine Consolidation in Cloud Computing”, International Journal of Innovative Research in Computer and Communication Engineering, Vol. 3, Issue 5, May 2015.
35. Lskrao Chimakurthi, Madhu Kumar S D, “Power Efficient Resource Allocation for Clouds Using Ant Colony Framework”, International Conference on Advances in Computing and Communication ICACC-2011, NIT Hamirpur, India (2011).
36. Wei-Tao Wen,Chang-Dong Wang, De-Shen Wu,Ying-Yan Xie, “An ACO-based Scheduling Strategy on Load Balancing in Cloud Computing Environment”, Ninth International Conference on Frontier of Computer Science and Technology, 2015
37. Dorigo M. Optimization, learning and natural algorithms. Phd thesis, Italy (Milano, Italy): Politecnico di Milano; 1992.
38. M. Dorigo, M. Birattari, T. Stützle, Ant Colony Optimization-- Artificial Ants as a Computational Intelligence Technique, IEEE Computational Intelligence Magazine, 2006.
39. Ludwig S, Moallem A. Swarm intelligence approaches for grid load balancing. J Grid Comput 2011; 9(3):279–301.
40. Buyya, R., Ranjan, R., Calheiros, R.N., "Modeling and Simulation of Scalable Cloud Computing Environments and the CloudSim Toolkit: Challenges and
2015-2016 Page 83
Opportunities" in Proceedings of the 7th High Performance Computing and Simulation (HPCS 2009) Conference, Leipzig, Germany, 2009.
41. Calheiros, R.N., Ranjan, R., Beloglazov, A., De Rose, C.A.F., and Buyya, R., “CloudSim: a toolkit for modeling and simulation of cloud computing environments and evaluation of resource provisioning algorithms.” In Software: Practice and Experience, 41(1): pp. 23-50, (2011).
42. Mala Kalra, Sarbjeet Singh, A review of metaheuristic scheduling techniques in
cloud computing, In Egyptian Informatics Journal (ELSEVIER), Volume 16, Issue 3,
November 2015, Pages 275-295, ISSN 1110-8665.
43. A. Beloglazov and R. Buyya, “Optimal online deterministic algorithms and
adaptive heuristics for energy and performance efficient dynamic consolidation of
virtual machines in cloud data centers,” Concurrency Comput.: Prac. Exp., vol.
24, no. 13, pp. 1397–1420, 2012.