Open Access This article is
- freely available
Sensors 2019, 19(6), 1267; https://doi.org/10.3390/s19061267
Improving Quality-of-Service in Cloud/Fog Computing through Efficient Resource Allocation †
ISAT Laboratory, Department of Computer Science, University of the Western Cape, Bellville 7535, South Africa
Correspondence: [email protected]
This paper is an extension version of the conference paper: Akintoye, S.B.; Bagula, A. Optimization of virtual resources allocation in cloud computing environment. In Proceedings of the IEEE AFRICON, Cape Town, South Africa, 18–20 September 2017.
Received: 11 January 2019 / Accepted: 9 February 2019 / Published: 13 March 2019
Recently, a massive migration of enterprise applications to the cloud has been recorded in the IT world. One of the challenges of cloud computing is Quality-of-Service management, which includes the adoption of appropriate methods for allocating cloud-user applications to virtual resources, and virtual resources to the physical resources. The effective allocation of resources in cloud data centers is also one of the vital optimization problems in cloud computing, particularly when the cloud service infrastructures are built by lightweight computing devices. In this paper, we formulate and present the task allocation and virtual machine placement problems in a single cloud/fog computing environment, and propose a task allocation algorithmic solution and a Genetic Algorithm Based Virtual Machine Placement as solutions for the task allocation and virtual machine placement problem models. Finally, the experiments are carried out and the results show that the proposed solutions improve Quality-of-Service in the cloud/fog computing environment in terms of the allocation cost.
Keywords:CloudSim; virtual machine; greedy heuristics; cloud computing; fog computing; genetic algorithm; data center; CloudSim and hungarian algorithm
Cloud computing is a computing model to provide on-demand network access to a large pool of networking, storage and computing resources over the internet . This type of computing provides cost reduction because customers do not need to procure hardware for their operations, rather they subscribe for computing resources from the Cloud Service Provider (CSP) only when the cloud services are needed and also only pay for services they consume. Basically, cloud computing is grouped into four deployment models: Private cloud, community cloud, hybrid cloud and public cloud [1,2]. A private cloud is solely owned and managed by an individual organization. In the community cloud model, the cloud infrastructures are owned and shared by various organizations and supports a specific community that has similar operations. The hybrid cloud is a combination of two or more clouds such as public, private and community that remain distinctive entities but are joined together by uniform technology that enables data and applications to be moved easily. In the public cloud model, the cloud infrastructures are made available to the public on a pay-as-you-use basis by the CSP. Broadly speaking, cloud computing is divided into three service models as follows: Platform-as-a-Service (PaaS), Software-as-a-Service (SaaS) and Infrastructure-as-a-Service (IaaS). PaaS allows users to rent virtualized platforms on which to run their own applications or services . In the SaaS model, the cloud customers use the provider’s applications running on a cloud infrastructure. In IaaS, customers are provided with CPU, network bandwidth, storage and other computing resources, all of which they are subsequently able to reconfigure as needed. Invariably, the cloud services are offered to cloud customers and users through the concept of virtualization and distributed computing. Virtualization is an abstraction of computing resources such as storage and processing power to provide virtualized resources called virtual machines (VMs) for customer’s applications . Virtualization technology can be classfied into four groups, namely: Full virtualization, para-virtualization, native virtualization and operating system-level virtualization. Full virtualization provides a full image of the essential hardware. Para-virtualization modifies a guest operating system and is able to communicate directly with the hypervisor . In native virtualization, the guest operating system and host use the same hardware. Operating system-level virtualization does not depend on a hypervisor, rather it modifies the operating system to isolate securely many instances of an operating system within a single host machine. In cloud computing, virtualization technologies such as network, storage and compute offer users an abstraction layer (i.e., VM) that provides a uniform computing platform by concealing the underlying hardware heterogeneity, internal management difficulty and geographic boundaries . When the cloud receives a task request from a user, either a new VM is initialized or an existing VM of the same user is assigned to the request . After the task is processed successfully, every assigned resource is released to the pool of free resources. Sometimes, the number of the available physical resources may not be commensurate with the number of task requests from the cloud user, then resource allocation becomes a critical problem which needs to be solved by CSPs. In such cases, the CSP has the responsibility to determine the number of VMs to be initiated, based on the number of requests from cloud users. The problem of resource allocation in cloud computing involves assigning tasks to VMs and the placement of VMs on Physical Machines (PMs). The computing resource provided is normally allocated based on the Service Level Agreement (SLA) contract between the cloud customers and service providers. The SLA spells out the details regarding the quality of service (QoS) to be offered by the CSP in terms of a range of performance parameters such as reliability, response time, and throughput. The SLA may also specify the payment process and the breach of SLA contract penalty . Thus, the ultimate goal of the CSP is to optimize resource utilization and maximize profit while that of the cloud user is to ensure the cost of leasing the resources is minimized.
1.1. Cloud/Fog Computing Resource Management Framework
The resource management framework in Figure 1 summarizes the work described in this paper. The multi-layer framework includes:
- A physical resource layer which is composed of data centres that host PMs in the form of host machines. The PMs are interconnected by switches (SWs).
- A virtual resource layer which lies above the physical resource layer to virtualize the physical resources as VMs for better resource management.
- An application layer which lies above the virtual resource layer to provide a variety of services to users. These include SaaS, PaaS and IaaS.
When considered from a service perspective, the framework in Figure 1 can be presented as a two-layer architecture including:
- A virtual resource scheduling module, where a mapping between physical machines and the virtual machines is made. We assume in this paper that each physical machine (host machine) provides at least one virtual machine.
- A task allocation management module enabling the virtual resources to be allocated to the users in a cost effective way.
This paper proposes an implementation of the framework by assuming that: (i) The tasks and virtual resources are varied and the physical resources are uniform, and (ii) the number of on-demand requests initiated by cloud users is higher than the number of available resources. In this work, we propose a model for assigning the tasks (cloudlets) to VMs, and VM placement with the aim of improving quality of service in the cloud/fog computing environment. The main contributions of this paper are outlined as follows:
- Problem formulation: The task allocation and VM placement problem models in the cloud computing environment are formulated and presented. These models aim to minimize the resource allocation cost in a setting where multiple cloud user requests have to be processed on a limited number of physical resources.
- A task assignment strategy: We propose the Hungarian Algorithm Based Binding Policy (HABBP) as a heuristic solution to the linear programming problem, and use the algorithm to implement a novel assignment strategy for the famous CloudSim simulator. We also propose the assignment strategy module as a contributed module to CloudSim which includes: (i) A graphical user interface as a front-end component which enables cloud users to interact and communicate with CloudSim and to configure the tasks, VM and PM parameters from the interface, rather than embedding parameter values in the CloudSim source code and (ii) a novel assignment strategy as a back-end component.
- VMs placement solution: We propose a Genetic Algorithm Based Virtual Machine Placement (GABVMP) to solve and optimize the VM placement problem in the cloud computing environment.
- Analysis of experimental results: We evaluate and compare the performance of the proposed binding policy with the conventional binding policy implemented by the CloudSim simulator and benchmark both solutions against the Simplex algorithm commonly used as a linear programming solver. The proposed GABVMP solution is also compared with the greedy heuristics: Random Placement and First Fit Placement.
1.3. Paper Organization
The rest of the paper is arranged as follows: Section 2 presents existing works related to the resource allocation problem in cloud computing. The linear programming model for task allocation is proposed in Section 3. Section 4 presents a task allocation algorithmic solution as a solution for the optimization of the task allocation problem model. Section 5 describes the VM placement problem. In Section 6, the VM placement problem is solved using GABVMP. Section 7 describes the implementation of HABBP and GABVMP, for task allocation and VM placement, respectively. Lastly, we conclude our paper with Section 8.
2. Related Work
In cloud/fog computing, resource allocation is the process of assigning available resources to the needed cloud applications over the internet. These resources are allocated based on cloud user request and pay-per-use method. Resources in cloud computing could be either virtual resources or physical resources. Cloud service providers must effectively manage, provide, and allocate these resources to provide services to cloud consumers based on service level agreements (SLAs). Therefore, the appropriate allocation of resources in cloud data centers is also one of the important optimization problems in cloud computing especially when the cloud infrastructure is made of lightweight computing devices.
The quality of service in cloud/fog computing is based on its resource allocation process, and the cloud service provider should assign the resource to the cloud users in an optimal way. The result of any optimal resource allocation strategies must consider certain parameters such as latency, throughput, reduction of energy consumption, minimization of allocation cost and response time. There are many existing works relating to resource allocation in cloud/fog computing. Maguluri et al.  propose a stochastic model for resource allocation in cloud computing in which jobs arrive according to a stochastic process and request a variety of virtual machines. The authors use a non-pre-emptive for load balance among the cloud servers and to schedule VM configurations. In order to minimize the communication complexity, the authors consider a distributed system such that each server maintains its own queues. The experimental evaluations reveal that there is only a small difference in delay performance between distributed and centralized queueing systems. Furthermore, the evaluations show that the non-pre-emptive algorithm adopted in this work outperforms the best-fit scheduling algorithm in terms of throughput. Baker et al.  present a requirements model for the runtime execution and control of an intention-oriented Cloud-Based Application. The requirements modelling process known as Provision, Assurance and Auditing, and an associated framework are defined and developed where a given system’s functional and non-functional requirements are modelled in terms of intentions and encoded in a standard open mark-up language. An autonomic intention-oriented programming model, using the Neptune language, then handles its deployment and execution. Al-khafajiy et al.  propose a fog computing architecture and framework to improve QoS through the request offloading method. The proposed method uses a collaboration strategy among fog nodes in order to permit data processing in a shared mode which satisfies QoS and serves the largest number of IoT requests. The experimental result shows that the performance of fogs layer is significantly increased when the overload is distributed over several fog nodes.
In  the author investigates existing resource scheduling algorithms, and classfies them according to some determining factors, such as cost, energy and time. The advantage of the study is that it helps CSPs in the adoption of appropriate scheduling algorithms based on their ultimate goals. Liu et al.  propose an earliest finish time duplication algorithm to schedule multiple tasks in heterogeneous data centres. The algorithm can also be referred to as a directed acyclic graph based scheduling algorithm. The performance evaluation of the study reveals that the combination of pre-processing the cloud resources before scheduling and the proposed algorithm, performs better than the heterogeneous earliest finish time algorithms, in terms of task scheduling time. In  the authors propose a virtual cloud resource allocation model based on constraint programming to improve the Quality-of-Service (QoS) in cloud computing and decrease the cost of resource utilization. Moreover, the authors  propose a VM Repacking Scheduling Problem (VRSP) to minimise the energy consumption while placing VM in the data centres. The benefit of the study is that it is flexible, it enables users to generate automatically the SLA constraints, and it reduces energy utilization.
In order to address the VM placement problem in a data centre, the authors  propose a greedy-based algorithm to reduce resource usage, the network traffic and the number of cloud servers. The work divides traffic flows and routes them through two link-disjoint paths to decrease congestion, at the same time meeting the requirements for protection grade as well as bandwidth. Furthermore, the authors  propose an online heuristic-based VM placement algorithm which is based on a multi-dimensional space partition model. The objective of the work is to make a trade-off between balancing multi-dimensional resource usage and reducing the number of the PMs used for VM placement. The advantage of the algorithm is that it reduces the number of running PMs as well as the total energy consumption. In , authors propose an ant-colony based optimization model with the aim to optimize resource utilization and total power consumption concurrently. The model performs better than the previous multi-objective VM placement algorithm. Pascual et al.  propose multi-objective evolutionary algorithms to solve the placement problem. The objectives of work are: (i) The consolidation of VMs on a small set of processors, and (ii) the minimization of associated energy costs for servers and network equipment. The algorithms were implemented using a Flat Tree topology and tiered applications, such as a web server with an associated database. The major advantage of the algorithms is that they enhance the application performance and energy consumption. The work in  proposes algorithms for the placement of precedence-constrained parallel virtual machines. The aim of the work is to reduce energy consumption by consolidating virtual machines on the available physical machines yet not degrading the makespan. The algorithms were evaluated using benchmarks of real-world distributed applications and they achieved efficient results.
Georgiou et al.  propose VM placement algorithms for the Portland network architecture with the aim to allocate communicating virtual machines in physical proximity to avoid the creation of network bottlenecks. The authors propose two algorithms: the first algorithm is proposed for rapid placement of closely located virtual machines, while the second algorithm is designed to identify network regions that can best host the virtual machines and then, using the first algorithm, maps these virtual machines on the servers. The benefit of the approach is that it has the capability to reduce the intensity of traffic in the links of top-level switches.
Meng et al.  propose a Cluster-and-Cut algorithm to improve the scalability of data center networks with traffic-aware VM placement. The goal of the algorithm is to reduce network traffic among VMs and related communication cost by placing inter-communicating VMs in the same PM. The VM placement problem is formulated as a quadratic assignment problem (QAP) to find a suboptimal placement which minimizes network traffic, considering the associated communication cost and a static-single path routing. The allocation cost is defined as the number of switches between two inter-communicating VMs and each PM is divided by slots with the capacity to accommodate a single VM with the assumption of an equal number of VMs and slots. If the number of VMs is lower than the number of slots, dummy VMs are introduced with zero traffic which has no significant effect on the solution of the problem. The performance evaluations of the algorithm show a significant performance improvement compared to existing genetic algorithmic methods.
Breitgand et al.  investigate the problem of placing images and VM instances on the servers with the aim to increase the affinity between them to mitigate communication overhead and latency. The problem is modelled as an extension of the Class Constrained Multiple Knapsack problems (CCMK) and present a polynomial time local search algorithm for the same size images. Specifically, this model focuses on an off-line placement problem, where there are a given set of demands and available servers. In order to solve this problem, the local search algorithm was applied as a basis for ongoing optimization which periodically improves the VM placement and greedy placement of a new set of VM instances by allowing migrations of the VMs.
Vakilinia et al.  propose a platform for virtual machine (VM) placement/migration to minimize the total power consumption of cloud data centers (DCs). The platform is divided into two parts. Firstly, an estimation module is introduced to predict the incoming load of the DC. Secondly, two schedulers are designed to determine the optimal assignment of VMs to the PMs. The proposed schedulers apply a column generation method to solve the large-scale optimization problem in conjunction with the cut-and-solve-based algorithm and the call back method to decrease the complexity and the time to obtain the optimal solution. The trade-off between optimality and time is investigated. The numerical results show that the proposed platform produces the optimal solution for a limited time-frame. Selmy et al.  present virtual machines migration and selection policies to reduce the power consumption of servers in the cloud computing environment. The authors propose neural networks for classification and prediction, Self Organizing Map (SOM) and K-Means Clustering algorithms for the policies. The results of implementation of the proposed policies show significant reduction of energy consumption of the servers in the data center.
All the works mentioned above have been able to solve one or two problems of VM placement in the cloud computing environment. There is still much to be done, however, to mitigate the effect of these problems.
3. Task Allocation Problem Model
In this section, we present a linear programming problem model for assigning task requests (cloudlets) from cloud users to VMs. To express the model mathematically, we consider a set of VMs represented by for and . Similarly, a set of tasks (cloudlets) corresponding with each on-demand user request (job) represented by for and . In this work, we assume a one-to-one allocation model where each VM executes only one cloudlet and each cloudlet needs to be assigned to only one VM. However, a many-to-one allocation model may also be considered where several tasks are allocated to a single virtual machine. The many-to-one allocation model is not considered in this paper.
Furthermore, we set and to be an matrix in which is the cost of assigning to , i.e.,
We also set to be the matrix where
Our goal is to minimize the total cost , defined as the sum of the cost of assigning cloudlets to the available VMs. Thus, we present an optimization problem as a linear programming model in terms of a function as follows:subject to the following constraintsandsuch that
Thus, any matrix satisfying the Equations (4) and (5) is a solution and conforms to a permutation of a set generated by setting if and only if . In addition, if is a solution relating to , thensummation over i from 1 to n, we obtain
Hence, any solution on which is minimal is known as an optimal solution. We can reform a given allocation problem specified by C into another one specified by a matrix , in which , ∀ pairs , where the two problems have the equal set of optimal solutions. If is an optimal solution to the problem given by , then it is important to know that is also an optimal solution to the one given by C.
Theorem 1 illustrates the steps to reform a matrix into another with the same set of optimal solutions.
A solution X is an optimal solution for if and only if it is an optimal solution for where for any of and and and are real numbers for all i and j.
4. Task Allocation Algorithmic Solution
In this section, we present a task allocation algorithmic solution that is based on Hungarian algorithm [24,25] known as Hungarian Algorithm Based Binding Policy (HABBP) to solve the task allocation problem in the cloud computing environment.
4.1. Notation and Preliminaries
- Given a cost-matrix of size ,
- n is the number of VMs,
- m is the number of cloudlets,
- represents the time required to complete by .
4.2. Procedures of the Algorithm
Algorithm 1 represents the pseudo-code of the HABBP for tasks-to-VMs allocation in a cloud computing environment. The first four lines (1–4) in the algorithm represent the initialization of different variables. Subsequently, we initialize cost-matrix by dividing the cloudlet length by the MIPS of VM. In the case of many-to-one allocations where the number of cloudlets and the number of VMs are not equal, we then add the dummy cloudlets/VMs to turn the cost-matrix into a square matrix.
|Algorithm 1: Computation of the total assignment cost C.|
Thereafter, we compute the reduced-cost-matrix from the cost-matrix by subtracting the minimum value of each row from the elements of its row, turning each minimum value into zero, and by subtracting the minimum value from the elements of each column, turning the minima into zeros. From that, we compute the line-cost-matrix. If the number of lines is not equal to the number of VMs, we then subtract the minimum uncovered element from every covered element. If an element is covered twice, we then add the minimum element to it.
Lastly, we apply the mapping to the original matrix, discarding dummy rows, and we add the cost of assigning cloudlets to VMs to give the total minimum cost C.
We illustrate, through an example, the concept of the HABBP and the steps that need to be followed in order to optimize the assignment of tasks to virtual resources in the cloud computing environment. Table 1 depicts three cloudlets in the queue with a broker and Table 2 depicts VMs initiated in the data centre.
The algorithm works as follows: We initialize the cost-matrix by dividing the length of the cloudlet by the mips of the VM as depicted in Table 3.
In this case, the number of cloudlets is equal to the number of VMs. Thus, we do not need to add the dummy cloudlet/VM values to turn the cost-matrix into a square matrix. We compute the reduced-cost-matrix by subtracting the minimum value of each row and column from the row and column of the cost-matrix to yield Table 4 and Table 5 respectively.
Then, we calculate the line-cost-matrix; this represents the lines that cover all zeros in the reduced-cost-matrix. In this case, there are two lines. The lines are on column 1 and row 2 of the reduced-cost-matrix. Since the number of lines is not the same as the number of VMs, we remove the lowest of all uncovered elements from all uncovered elements as indicated in Table 6.
Again, we calculate the minimum number of lines required to cover all zeros in the matrix. The lines are on column 1, row 2 and row 3 of the reduced-cost-matrix. Since the number of lines is the same as the number of VMs, an optimal assignment exists among the zeros in the reduced-cost-matrix. Therefore, is assigned to , is assigned to , and is allocated to as indicated in Table 7.
The total cost of assigning cloudlets to virtual machines optimally is: 100 s + 120 s + 160 s = 380 s.
Alternatively, we solve the example mentioned above using Simplex method [26,27] and compare the result with the one that is already generated using HABBP. Using the Equations (3)–(6), the optimization objective function can be formulated as:subject to the following constraintsand
Since the objective function is in minimization form, then we convert it into maximization form and add the artificial variables as:and
In Phase 1 of the two-phase simplex method, we remove the artificial variables and find an initial feasible solution of the original problem which gives the final Tableau in the Table 8.
The basic feasible solution at the end of Phase 1 computation is used as the initial basic feasible solution of the problem. The original objective function is introduced in Phase 2 computation and the usual simplex procedure is used to solve the problem. The Phase 2 gives final optimal value in Table 9.
Similar to the HABBP, the simplex method gives the total optimal cost of assigning cloudlets to virtual machines as 100 s + 120 s + 160 s = 380 s. That is, is assigned to , is assigned to , and is allocated to .
5. Virtual Machine Placement Problem
In this section, the problem of optimally placing a set of VMs into a set of PMs in the single cloud environment is formulated. As depicted in Figure 2, the tree network topology consists of five PMs and connection points called switches (SWs). The placement of any VM in a PM will be determined by at least a switch node in the figure. In the light of that, there will be huge end-to-end traffic between a given VM and the switch which the VM is dependent on.
It is assumed that the intensity of communication between PMs is negligible compared to the intensity of communication between PMs and SWs. Placing the VMs in PMs that offer an optimal placement cost according to the demands of the VMs will be a major determinant factor in this work. Each PM-SW pair is associated with a cost. Thus, it will not be a good idea to place a VM with intensive demand for a switch in a PM that has a high cost associated with that switch.
The VM placement problem in the data center network can be represented mathematically as a graph , where P is a set of PMs, S is a set of SWs, and E is a set of links between the PMs and SWs. The links are weighted and represent the cost between any PM-SW pair. In addition, it is also assumed that there is no congestion in the links between the PMs and SWs. The links have enough capacity to handle the switch flow demands of VMs appropriately. More information about the network is as follows.
- P = is a set of PMs.
- V = is a set of VM requests.
- S = is a set of switches.
- is the latency between and .
- is the bandwidth for link.
- represents MIPS of each .
- represents MIPS of each .
- represents utilization of .
- is the power consumed by when it is doing nothing but powered on.
- is the power consumed when the is fully loaded/utilized or at the peak load.
Consider a VM to be placed into PM through the SW in a data center network, the following assumptions are made.
- Each PM has different latency to all SWs in the network.
- Each PM has one and only one link to the SW in the network.
- Each PM can accommodate more than one VM depending on the capacity of the PM.
- Each link between PMs and SWs has enough capacity and there is no congestion on the links.
- The number of VMs, PMs and SWs are equal i.e., .
5.3. The Mathematical Model
The cost in terms of the time taken to use the link is defined as:where denotes size (MB) of the routed through the link.
The placement of a into a depends on the latency between and , and the cost associated with the link. Thus, the total cost to place into through is computed as,where and is the weighting for the link and latency. The goal is to place VMs into PMs such that the total placement cost for the PM-SW links consumption and latency between VM and SW is minimized. Thus, an optimization model is defined as follows:wheresubject to
Equation (19) ensures that each VM is mapped to one PM and all VMs are placed. Also, Equation (21) ensures that the total MIPS of VMs placed on a PM should not exceed its capacity. For a given PM, the sum of the MIPS requirements of all VMs placed on it should be less than or equal to the total available capacity of the PM.
Furthermore, it is assumed that there is a linear relationship between the power consumption and utilization of a physical machine in a data center. The energy consumed, , by a PM can be calculated as shown in :wherewhere is a set of virtual machines placed on the .
Thus, the total energy consumed by the PMs after VMs placement can be calculated as
6. Virtual Machine Placement Algorithmic Solution
The section presents the Genetic Algorithm Based Virtual Machine Placement (GABVMP) for solving the Virtual Machine Placement problem in the cloud computing environment.
6.1. Genetic Algorithm Based Virtual Machine Placement
Genetic Algorithm (GA) is a computerized search and optimization algorithm based on the mechanics of natural genetics and natural selection. The GA is proposed by John Holland  where each potential solution is encoded in the form of a string and a population of strings is created which is further processed by three operators: Reproduction, crossover, and mutation. Reproduction is a process in which individual strings are copied according to their fitness function. Crossover is the process of swapping the content of two strings at some point(s) with a probability. Lastly, mutation is the process of flipping the value at a particular location in a string with a very low probability.
Figure 3 describes the GABVMP. The algorithm consists of four parts: Input, initialization, looping and output. In the initialization part, the set of physical machine chromosomes which are also known as population, is generated randomly. The looping part contains fitness evaluation and checks if the optimal solution condition is met according to the optimization objectives. If not, the looping continues, the selection, crossover, mutation and replace functions are applied sequentially. At the end of the loop, the optimal solution will be produced as the output.
Each chromosome in the GABVMP contains genes which represent the allocated physical resources and switches to the virtual resources. The value of a gene positive integer representing the identity of the VM being placed in the PM through SW. For Example, let be a set of VM to be placed in the a set of PM through a set of SW in a data center network. Let’s assume that are links between PMs and SWs which is one of the factors to be considered while placing VMs on the PMs. The initial population contains a set of PM-SW link chromosomes where the genes represent the identity of VMs. The initial population is generated randomly by using Algorithm 2.
|Algorithm 2: Initial population algorithm.|
6.3. Fitness Evaluation
The objective is to minimise the total cost of placing VMs on the PMs through SWs. As defined in Section 5, The VM placement cost consists of the cost of PM-SW link usage and the latency between the VM and SW. The objective function used by the GABVMP is the same objective function as that of the mathematical model. Thus, the fitness value of each chromosome is calculated as,
6.4. Generating the Next Population
A new population is generated from an initial population of solutions using their fitness values and genetic operators: Selection, crossover, mutation and reproduction. In order to generate a new population, individuals are selected for participation and the genetic operators are applied as follows.
6.4.1. Selection Process
To select the best chromosomes that would pass their genes into the next generation, the fitness proportionate selection approach is implemented using roulette wheel selection. The fitness function is the total cost of the VM placement represented by each chromosome. The lower the total cost, the fitter the VM placement represented by that chromosome . Thus, the chromosomes with lower values are selected for the generation of the next population.
6.4.2. Crossover Operator
The crossover operator works on two parent chromosomes and produces a new individual. In GABVMP, a midpoint crossover with crossover probability 0.8 is adopted and crossover operator process is described in Algorithm 3. Figure 4 shows two parent and offspring chromosomes before and after mid crossover respectively.
|Algorithm 3: Crossover function.|
| input: , : two parent chromosomes|
output: , : two offspring chromosomes
2 = ;
3 mid cross point;
6 return , .
6.4.3. Mutation Operator
In the GABVMP, the next operation is mutation of the offspring. Mutation helps to prevent premature convergence and promotes diversity in the population. In other words, it helps to avoid getting trapped in local solutions. In this work, inversion mutation is adopted where a subset of genes in a chromosome is selected and inverted to form mutated offspring. Figure 5 illustrates the inversion mutation operation on the offspring 1. In offspring 1, a subset of genes (1, 5, 2, 6) in chromosome (7, 8, 1, 5, 2, 6, 4, 3) are selected and inverted to give a new chromosome (7, 8, 6, 2, 5, 1, 4, 3).
The replacement operator replaces old chromosomes in the current population with the new chromosomes to form a new population.
6.4.5. Stopping Criterion
GABVMP stops either when the maximum number of generations is reached or the optimal total placement cost is obtained.
The comparison of the GABVMP and the existing related VM placement approaches as mentioned above is presented in Table 10. The comparison parameters include: Latency awareness, energy awareness, network awareness, Internal traffics, flow path allocation and the method adopted to solve the VM placement problem.
7. Experimental Results
In this section, we evaluate the performance of our proposed models. We carried out experiments on a desktop computer with specifications: Intel Core i7 CPU @ 2.80 GHz CPU and 4 GB RAM.
7.1. Implementation of the Proposed HABBP
We implemented the proposed HABBP on the famous open source cloud simulator known as CloudSim  Netbeans IDE 8.2. CloudSim is developed by the Cloud Computing and Distributed Systems (CLOUDS) Laboratory as an extensible Java-based open source framework for modelling and simulation of cloud computing infrastructures and services. Garg et al.  refer to CloudSim as an advanced simulator for cloud computing infrastructures and services with great properties such as scaling as well as a low simulation overhead. It provides classes for data centres, VMs, applications, users, computational resources, and scheduling policies. As depicted in Figure 6, there are different stages of the CloudSim life cycle ranging from initialization of cloud infrastructures to the simulation results. Our goal is to validate the performance gains derived from the proposed HABBP compared to the default task assignment strategy as implemented in the CloudSim.
The main disadvantage of the current CloudSim, however, is the lack of a graphical user interface (GUI) that allows cloud users to configure cloudlets and the cloud infrastructure parameters, and the lack of optimal cloudlets-to-VMs assignment strategy. In the current work, we extended CloudSim to (i) implement and integrate a graphical user interface using a java Jframe class as shown in Figure 7 and (ii) introduced a new cloudlets-to-VMs assignment strategy by creating a new method called TaskAllocationAlgorithmicSolution() in the DatacenterBroker class of CloudSim.
The model was implemented by assigning each VM to different PMs of the same capacity and all PMs were located in the same data centre. Subsequently, we simulated five jobs using HABBP, default assignment strategy and the Simplex algorithm to assign cloudlets to VMs in CloudSim. Each job had 20 cloudlets and they assigned them to heterogeneous VMs. Each cloudlet and VM had different lengths and MIPS values respectively. We assumed that other parameters, such as file size, output size values of all cloudlets, size, ram, bandwidth and pesNumber of all VMs, were constant, as shown in Table 11 and Table 12.
The simulation results are presented in Table 13 and Table 14, Figure 8 and Figure 9, and plotted in Figure 10 and Figure 11. In job 1, under the default assignment strategy, cloudlets were assigned to the VMs sequentially, that is to , to , to , to , to , etc. On the other hand, HABBP assigned cloudlets to VMs based on the operations in HABBP. For instance, is assigned to , to , to , to , to , etc. in job 4; see Figure 8.
In addition, we also compared the overall performance of HABBP with the default assignment strategy and benchmarked both solutions against the Simplex algorithm in terms of the computational time of cloudlets in each job and the total processing time of individual jobs. In Figure 10a–e, it can be seen that some cloudlets took a slightly longer time to complete in HABBP than in the default assignment strategy, while some other cloudlets took a significantly longer time to complete under default assignment strategy than under HABBP. Figure 10f, however, where the total processing time performance of different jobs for HABBP and default assignment strategy is presented, shows that HABBP constantly outperformed the default assignment strategy. Take Job 2 as an example, compared to the default assignment strategy, the total processing time for HABBP was reduced by 54.73% compared with that of the default assignment strategy. HABBP and the Simplex algorithm produced the same optimal allocation cost. HABBP, however, outperformed the Simplex algorithm in terms of computational time as shown in Table 15 and Figure 11.
7.2. Implementation of the Proposed GABVMP
In this section, the efficiency of the proposed GABVMP as discussed in Section 6 is evaluated. For the simulation, the mininet module in python3 was used to model the tree topology of the PMs and SWs interconnected in the datacenter. The network topology consisted of equal pairs of PMs and SWs. Each PM-SW link in the network topology had a different capacity in terms of Mbps. The proposed GABVMP and greedy heuristics (Random Placement and First Fit Placement) were implemented and their behaviors were compared on the topology with different numbers of PMs and SWs.
Three experiments were carried out. In the first experiment, 5, 10, 15, 20, 25, 30, 35, 40 VMs were placed on 5, 10, 15, 20, 25, 30, 35, 40 PMs interconnected with the same number of switches using GABVMP with different values of and . In the second experiment, 5, 10, 15, 20, 25, 30, 35, 40 VMs were placed on 5, 10, 15, 20, 25, 30, 35, 40 PMs interconnected with the same number of switches using Random Placement with different values of and .
In the last experiment, 5, 10, 15, 20, 25, 30, 35, 40 VMs were placed on 5, 10, 15, 20, 25, 30, 35, 40 PMs interconnected with the same number of switches using First Fit Placement with different values of and .
Figure 12 shows the experimental results of total placement cost in terms of time to implement the proposed GABVMP and the other two existing assignment methods in a data center network with tree topology consisting of 5, 10, 15, 20, 25, 30, 35, 40 of PMs and SWs at different values of of and . The GABVMP had a lower cost to place VMs on PMs than the Random Placement and First Fit Placement. For instance, at = 0.2 and = 0.8, the Random Placement had a total placement cost of 266 s and the First Fit Placement had a total placement cost of 205 s while GABVMP took a total placement cost of 116 s to place five VMs on five PMs interconnected with five SWs. For = 0.5 and = 0.5, the Random Placement had a total placement cost of 275 s and the First Fit Placement had a total placement cost of 235 s while GABVMP took a total cost of 125 s to place five VMs on five PMs interconnected with five SWs. For = 0.8 and = 0.2, the Random Placement had a total cost of 284 s and the First Fit Placement had a total placement cost of 216 s while GABVMP took a total cost of 134 s to place five VMs on five PMs interconnected with five SWs.
In addition, Figure 13 illustrates the impact of latency on the total assignment cost of the proposed GABVMP. The higher the value of which denotes the weight of latency, the higher the total placement cost. For instance, when = 0.2, the total placement cost was 1947 s, when = 0.5, the total placement cost was 1970 s and = 0.8, the total placement cost was 1992 s to place 20 VMs into 20 PMs.
Finally, Figure 14 shows the plot for energy consumption vs. number of VMs. The value of and was set to 300 J and 200 J respectively . It is observed from the figure that, when the number of VMs was increased, the energy consumed by the used PMs was also increased. Energy consumption in the proposed GABVMP, however, was lower than the Random Placement method. This is because the number of PMs required to place a given number of VMs was less in GABVMP than the Random Placement and First Fit Placement.
8. Conclusions and Future Work
The level of Quality-of-Service in cloud computing is determined to a large extent by the resource allocation strategy adopted. In this work, the issue of Quality-of-Service in cloud computing environments has been revisited. Two solution models have been proposed. Firstly, the tasks-to-virtual machines allocation problem as a linear-programming problem model was formulated and HABBP was proposed, a load balancing policy for binding cloudlets to virtual machines. The simulation results produced by the contributed code to the CloudSim simulation revealed the relative efficiency of the newly proposed HABBP policy in solving and optimizing the virtual resources allocation problem in the cloud computing environment. Secondly, the virtual machine placement problem was presented and proposed a GABVMP as the solution for optimizing the model. The simulation results show that the GABVMP performed better than the two greedy heuristics, Random Placement and First Fit Placement, in terms of PM-SW links consumption which corresponds to the cost of placing VMs on PMs in the data center.
In the near future, the proposed solutions will be used to optimize resource allocation in federated lightweight cloud computing infrastructures targeting not only drought mitigation [33,34] in the rural areas of Africa but also healthcare, following the framework proposed in [35,36]. For such deployments, the policy will be extended to account for traffic engineering characteristics of the cloud computing network for both local traffic  and inter-Africa traffic  as these can have a large impact on the access to the cloud nodes and thus influence the QoS provided by the cloud. Using UAVs/drones in the context of 5G as proposed in  is another alternative for deployment. The implementation of the newly proposed policy in a real and popular cloud computing management platform, such as OpenStack, is another avenue for future work.
Conceptualization, S.B.A. and A.B.; Methodology, S.B.A. and A.B.; Software, S.B.A.; Writing—original draft preparation, S.B.A.; Supervision, A.B.; Writing—review and editing, A.B.
National Research Foundation: NRF FREESTANDING.
Conflicts of Interest
The authors declare no conflict of interest.
- Mell, P.; Grance, T. The NIST Definition of Cloud Computing; National Institute of Standards and Technology: Gaithersburg, MD, USA, 2015. Available online: http://www.nist.gov/itl/cloud (accessed on 19 October 2015).
- Rimal, B.P.; Choi, E.; Lumb, I. A taxonomy and survey of cloud computing systems. In Proceedings of the Fifth International Joint Conference on INC, IMS and IDC, Seoul, Korea, 25–27 August 2009; pp. 44–51. [Google Scholar]
- Assante, D.; Castro, M.; Hamburg, I.; Martin, S. The Use of Cloud Computing in SMEs. J. Inf. Technol. Manag. 2016, 83, 1207–1212. [Google Scholar] [CrossRef][Green Version]
- Zhang, Q.; Cheng, L.; Boutaba, R. Cloud computing: State-of-the-art and research challenges. J. Internet Serv. Appl. 2010, 1, 7–18. [Google Scholar] [CrossRef]
- Chaudhary, V.; Minsuk, C.; Walters, J.P.; Guercio, S.; Gallo, S. A Comparison of Virtualization Technologies for HPC. In Proceedings of the 22nd International Conference on Advanced Information Networking and Applications (AINA 2008), Okinawa, Japan, 25–28 March 2008; pp. 861–868. [Google Scholar]
- Buyya, R.; Yeo, C.; Venugopal, S.; Broberg, J.; Brandic, I. Cloud computing and emerging IT platforms: Vision, hype, and reality for delivering computing as the 5th utility. Future Gener. Comput. Syst. 2009, 25, 599–616. [Google Scholar] [CrossRef][Green Version]
- Maguluri, S.T.; Srikant, R.; Ying, L. Stochastic models of load balancing and scheduling in cloud computing clusters. In Proceedings of the IEEE INFOCOM, Orlando, FL, USA, 25–30 March 2012; pp. 702–710. [Google Scholar]
- Baker, T.; MacKay, M.; Randles, M.; Taleb-Bendiab, A. Intention-oriented programming support for runtime adaptive autonomic cloud-based applications. Comput. Electr. Eng. 2013, 39, 2400–2412. [Google Scholar] [CrossRef][Green Version]
- Al-khafajiy, M.; Baker, T.; Waraich, A.; Al-Jumeily, D.; Hussain, A. IoT-Fog Optimal Workload via Fog Offloading. In Proceedings of the 2018 IEEE/ACM International Conference on Utility and Cloud Computing Companion (UCC Companion), Auckland, New Zealand, 2–5 December 2018. [Google Scholar]
- Lin, C.T. Comparative based analysis of scheduling algorithms for RM in cloud computing environment. Int. J. Comput. Sci. Eng. 2013, 1, 17–23. [Google Scholar]
- Liu, Z.; Qu, W.; Liu, W.; Li, Z.; Xu, Y. Resource preprocessing and optimal task scheduling in cloud computing environments. Concurr. Comput. Pract. Exp. 2014, 27, 3461–3482. [Google Scholar] [CrossRef]
- Zhang, L.; Zhuang, Y.; Zhu, W. Constraint Programming Based Virtual Cloud Resources Allocation Model. Int. J. Hybrid Inf. Technol. 2013, 6, 333–344. [Google Scholar] [CrossRef]
- Dupont, C.; Giuliani, G.; Hermenier, F.; Schulze, T.; Somov, A. An energy aware framework for virtual machine placement in cloud federated data centres. In Proceedings of the Future Energy Systems: Where Energy, Computing and Communication Meet (e-Energy), Madrid, Spain, 9–11 May 2012; pp. 1–10. [Google Scholar]
- Kanagavelu, R.; Bu-Sung, L.; DatLe, N.T.; NgMingjie, L.; MiAung, K.M. Virtual machine placement with two-path traffic routing for reduced congestion in data center networks. J. Comput. Commun. 2014, 53, 1–12. [Google Scholar] [CrossRef]
- Li, X.; Qiana, Z.; Lu, S.; Wub, J. Energy efficient virtual machine placement algorithm with balanced and improved resource utilization in a data center. J. Math. Comput. Model. 2013, 58, 1222–1235. [Google Scholar] [CrossRef]
- Gao, Y.; Guan, H.; Qi, Z.; Hou, Y.; Liu, L. A multi-objective ant colony system algorithm for virtual machine placement in cloud computing. J. Comput. Syst. Sci. 2013, 79, 1230–1242. [Google Scholar] [CrossRef]
- Pascual, J.; Lorido-Botran, T.; Miguel-Alonso, J.; Lozano, J. Towards a greener cloud infrastructure management using optimized placement policies. J. Grid Comput. 2014, 13, 375–389. [Google Scholar] [CrossRef]
- Ebrahimirad, V.; Goudarzi, M.; Rajabi, A. Energy-aware scheduling for precedence-constrained parallel virtual machines in virtualized data centers. J. Grid Comput. 2015, 13, 233–253. [Google Scholar] [CrossRef]
- Georgiou, S.; Delis, K.T.A. Exploiting network-topology awareness for vm placement in iaas clouds. In Proceedings of the 2013 International Conference on Cloud and Green Computing, Karlsruhe, Germany, 30 September–2 October 2013; pp. 151–158. [Google Scholar]
- Meng, X.; Pappas, V.; Zhang, L. Improving the scalability of data center networks with traffic-aware virtual machine placement. In Proceedings of the 2010 IEEE INFOCOM, San Diego, CA, USA, 14–19 March 2010; pp. 1–9. [Google Scholar]
- Breitgand, D.; Epstein, A.; Glikson, A.; Israel, A.; Raz, D. Network aware virtual machine and image placement in a cloud. In Proceedings of the 9th International Conference on Network and Service Management (CNSM 2013), Zurich, Switzerland, 14–18 October 2013; pp. 9–17. [Google Scholar]
- Vakilinia, S.; Heidarpour, B.; Cheriet, M. Energy Efficient Resource Allocation in Cloud Computing Environments. IEEE Access 2016, 4, 8544–8557. [Google Scholar] [CrossRef]
- Mohamed, H.K.; Alkabani, Y.; Selmy, H. Energy Efficient Resource Management for Cloud Computing Environment. In Proceedings of the 9th International Conference on Computer Engineering and Systems (ICCES), Cairo, Egypt, 22–23 December 2014; Volume 1. [Google Scholar]
- Kuhn, H.W. The Hungarian Method for the Assignment Problem. Nav. Res. Logist. Q. 1955, 2, 83–97. [Google Scholar] [CrossRef]
- Konig, D. Grafok es matrixok. matematikai es fizikai lapok. Matematikai Es Fizikai Lapok 1931, 38, 116–119. [Google Scholar]
- Dantzig, G.B. Programming in a Linear Structure; USAF: Washington, DC, USA, 1948. [Google Scholar]
- Dantzig, G.B. Linear Programming and Extensions; Princeton University Press: Princeton, NJ, USA, 2016; Volume 4. [Google Scholar]
- Lee, Y.; Zomaya, A. Energy efficient utilization of resources in cloud computing systems. J. Supercomput. 2012, 60, 268–280. [Google Scholar] [CrossRef]
- Holland, J. The Grid: Adaptation in Natural and Artificial Systems: An Introductory Analysis with Applications to Biology, Control, and Artificial Intelligence; University of Michigan Press: Ann Arbor, MI, USA, 1975. [Google Scholar]
- Su, F.; Zhu, F.; Yin, Z.; Yao, H.; Wang, Q.; Dong, W. New Crossover Operator of Genetic Algorithms for the TSP. In Proceedings of the 2009 International Joint Conference on Computational Sciences and Optimization, Sanya, China, 24–26 April 2009; Volume 1, pp. 666–669. [Google Scholar] [CrossRef]
- Calheiros, R.N.; Ranjan, R.; Beloglazov, A.; De Rose, C.A.F.; Buyya, R. CloudSim: A toolkit for modeling and simulation of cloud computing environments and evaluation of resource provisioning algorithms. Softw. Pract. Exp. 2011, 41, 23–50. [Google Scholar] [CrossRef]
- Garg, S.K.; Buyya, R. NetworkCloudSim: Modelling parallel applications in cloud simulations. In Proceedings of the Fourth IEEE International Conference on Utility and Cloud Computing (UCC), Victoria, Australia, 5–8 December 2011; pp. 105–113. [Google Scholar]
- Masinde, M.; Bagula, A. A framework for predicting droughts in developing countries using sensor networks and mobile phones. In Proceedings of the 2010 Conference of the South African Institute of Computer Scientists and Information Technologists, Bela Bela, South Africa, 11–13 October 2010; pp. 390–399. [Google Scholar]
- Masinde, M.; Bagula, A.; Muthama, T.N. The role of ICTs in downscaling and upscaling integrated weather forecasts for farmers in sub-Saharan Africa. In Proceedings of the Fifth International Conference on Information and Communication Technologies and Development, Atlanta, GA, USA, 12–15 March 2012; pp. 122–129. [Google Scholar]
- Bagula, A.; Mandava, M.; Bagula, H. A Framework for Supporting Healthcare in Rural and Isolated Areas. Elsevier J. Netw. Commun. Appl. 2018. [Google Scholar] [CrossRef]
- Bagula, A.; Lubamba, C.; Mandava, M.; Bagula, H.; Zennaro, M.; Pietrosemoli, E. Cloud Based Patient Prioritization as Service in Public Health Care. In Proceedings of the ITU Kaleidoscope 2016, Bangkok, Thailand, 14–16 November 2016. [Google Scholar]
- Bagula, A. Hybrid Traffic Engineering: The Least Path Interference Algorithm. In Proceedings of the SAICSIT 2004, Cape Town, South Africa, 4–6 October 2004; pp. 89–96. [Google Scholar]
- Chavula, J.; Suleman, H.; Bagula, A. Quantifying the Effects of Circuitous Routes on the Latency of Intra-Africa Internet Traffic: A Study of Research and Education Networks. In Proceedings of the e-Infrastructure and e-Services for Developing Countries, Lecture Notes of the Institute for Computer Sciences, Social Informatics and Telecommunications Engineering; Springer: Cham, Switzerland, 2014; Volume 147, pp. 64–73. [Google Scholar]
- Chiaraviglio, L.; Blefari-Melazzi, N.; Liu, W.; Gutiérrez, J.A.; van de Beek, J.; Birke, R.; Chen, L.; Idzikowski, F.; Kilper, D.; Monti, P.; et al. Bringing 5g into rural and low-income areas: Is it feasible? IEEE Commun. Stand. Mag. 2017, 1, 50–57. [Google Scholar] [CrossRef]
Figure 1. cloud/fog computing resource management framework.
Figure 2. Physical machines and switches in a tree network topology.
Figure 3. Genetic Algorithm Based Virtual Machine Placement.
Figure 4. Midpoint crossover.
Figure 5. Inversion mutation operation.
Figure 6. CloudSim Life cycle with HABBP.
Figure 7. CloudSim User Interface.
Figure 8. Assigning cloudlets to VMs using HABBP.
Figure 9. Assigning cloudlets to VMs using default assignment strategy.
Figure 10. Processing time of the cloudlets in Job 1, Job 2, Job 3, Job 4 and Job 5.
Figure 11. Comparison of computational time.
Figure 12. GABVMP vs. Random Placement vs. First Fit Placement.
Figure 13. GABVMP for and values.
Figure 14. Energy Consumption vs. Number of VMs.
Table 1. Cloudlet details.
Table 2. VM specifications.
Table 3. Initialize cost-matrix.
Table 4. Row reduced-cost-matrix.
Table 5. Column reduced-cost-matrix.
Table 6. reduced-cost-matrix.
Table 7. Optimal Assignment.
Table 8. Phase 1 final Tableau.
Table 9. Final optimal Tableau.
Table 10. Comparison of related VM placement problems.
|Paper||Latency-Aware||Energy-Aware||Network-Aware||Internal Traffic||Flow Path Allocation||Method Adopted|
|||No||Yes||No||No||No||Ant-colony based algorithm|
|||No||Yes||Yes||Yes||No||Multi-objective evolutionary algorithms|
|||No||No||Yes||Yes||Yes||Virtual Infrastructure Opportunistic fit (VIO) and VIcinity-BasEd Search (VIBES)|
|||Yes||No||Yes||Yes||No||Local search algorithm|
|||No||Yes||No||No||No||Column generation method, cut-and-solve-based algorithm and the call back method|
|||No||Yes||No||No||No||Neural networks, Self Organizing Map (SOM) and K-Mean Clustering algorithms|
Table 11. A set of jobs.
Table 12. A set of VMs.
Table 13. Default assignment strategy in CloudSim.
|proc. time||proc. time||proc. time||proc. time||proc. time|
|total processing time||7356||6147||7009||9842||8109|
Table 14. HABBP in CloudSim.
|proc. time||proc. time||proc. time||proc. time||proc. time|
|total processing time||3201||2783||3759||4425||3146|
Table 15. Comparison of computational time.
|HABBP||Default Assignment Strategy||Simplex Algorithm|
© 2019 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).