A Bio-inspired Approach for Power and Performance Aware Resource Allocation in Clouds

. In order to cope with increasing demand, cloud market players such as Amazon, Microsoft, Google, Gogrid, Flexiant, etc. have set up large sized data centers. Due to monotonically increasing size of data centers and heterogeneity of resources have made resource allocation a challenging task. A large percentage of total energy consumption of the data centers gets wasted because of under-utilization of resources. Thus, there is a need of resource allocation technique that improves the utilization of resources with effecting performance of services being delivered to end users. In this work, a bio-inspired resource allocation approach is proposed with the aim to improve utilization and hence the energy efficiency of the cloud infrastructure. The proposed approach makes use of Cuckoo search for power and performance aware allocation of resources to the services hired by the end users. The proposed approach is implemented in CloudSim. The simulation results have shown approximately 12% saving in energy consumption.


Introduction
Cloud computing enables access to shared pool of computing resources through internet on pay per usage basis [18]. The pool of resources needs to be managed efficiently in order to cut power costs. Energy consumption can be reduced by efficient allocation of resources. The aim of a resource allocation approach is to find a resource that fulfills resource demands of a given service without effecting its performance. Generally, resource allocation approach is either system centric or user centric. The former approach is traditional and emphasises on the improvement of overall system performance such a utilization. Whereas, the latter concentrates on providing quality of service to the endusers. In this paper, a novel resource allocation approach is proposed that improves the utilization of resources to enhance energy efficiency of the cloud infrastructure. Utilization of a resource and its energy consumption are highly coupled. A resource with low utilization consumes unacceptable amount of energy compared to its energy consumption when it is fully or sufficiently loaded. According to [7], an idle resource consumes up to 70% of the power consumed at full utilization. Furthermore, average resource utilization of most of the data centers is about 15-20% [21,13] which results in wastage of huge amount of energy. According to Koomey [15], "Total data center power consumption from servers, storage, communications, cooling, and power distribution equipment accounts for 1.7-2.2% of total electricity used in U.S. in 2010". Furthermore, today's data centers, in addition to their huge energy consumption, emit as much carbon dioxide as whole of Argentina. If left on their current path, data center carbon dioxide output will quadruple by the year 2020 [13]. While the cloud energy consumption is growing quickly, industrial organizations and researchers are finding ways to reduce energy consumption. The motivation for this work stems from challenges arising due to huge amount of energy consumption. The challenge is to enhance energy efficiency of the cloud infrastructure without effecting the performance of services delivered to the end users. The proposed work improves energy efficiency of the cloud by perspicacious allocation of resources to the services. Cuckoo search is employed for optimal allocation of resources to the services. The proposed approach is implemented in CloudSim. The simulation results have shown significant reduction in energy consumption.
Rest of the paper is organized as follows: Related work is presented in Section 2. In Section 3, power and performance aware resource allocation framework is discussed. Section 4 discusses Cuckoo search metaheuristic. Section 5 elaborates resource allocation using Cuckoo optimization. Results for performance analysis are discussed is Section 6. Conclusion and scope for future work are presented in Section 7. placement to minimize resource wastage and power consumption. The authors used only CPU processing speed and memory requirements of a VM while allocating resources to it. Feller et al. [8] presented multidimensional ant colony optimization based job consolidation algorithm. The algorithm uses resource utilization history to predict future resource demands and dynamically overbooks the resources. The authors tested the proposed algorithm on homogeneous PMs. Gao et al. [9] proposed multi-objective ant colony system algorithm for virtual machine placement that minimizes total resource wastage and power consumption. Ant colony optimization technique for assigning real-time tasks to heterogeneous processors is proposed by Chen et al. [6]. Local search technique is applied to improve energy efficiency of the feasible assignment solution generated by the proposed assignment algorithm. Huang et al. [11] presented genetic algorithm based adaptive sub-optimal resource management scheme to estimate number of VMs required to provide desired level of service. Kansal and Chana [12] presented artificial bee colony based energy-aware resource allocation technique to efficiently manage and enhance the utilization of resources. The authors have claimed the reduction of energy consumption and execution time of applications. Xu and Fortes [23] proposed multi-objective VM allocation algorithm. The authors have taken CPU, and memory parameters for VMs and have claimed reduction in power consumption, thermal dissipation costs, and resource wastage. In [20,4,19,10], the authors proposed energyconscious consolidation heuristics in order to conserve energy and maximize resource utilization without affecting the performance of the system. Kusic et al. [16] proposed performance and power efficient resourcemanagement approach based on look-ahead control method for virtualized heterogeneous environments. Prediction is employed for dynamic reallocation of resources. The next section describes proposed resource allocation approach.

Power and Performance Aware Resource Allocation
Resource allocation is a process of allocating required amount of computing resources to services hired by the end users. Services are provided through virtual machines (VMs). Multiple VMs can be executed in a single PM by leveraging virtual machine monitor (VMM) such as XEN [1], KVM [14], or VMWare [22]. The proposed power and performance aware resource allocation (P2RA) approach strives to increase utilization of resources without effecting the performance of services delivered to the end users. Figure 1 shows framework of proposed approach. The following are the few assumptions that are taken into consideration.
i. Services are independent of each other and have computational requirements such as CPU, memory, and bandwidth. ii. Each service can be allocated resources independently.
iii. Memory requirement of a service is rigid while CPU and network bandwidth requirements are fluid. A service can not be executed with less memory allocation than required. iv. A service can be executed with less CPU and bandwidth allocation than the required capacity at the cost of reduced performance. v. Idle PMs can be put to sleep mode to save energy.
Energy consumption for switching a PM from active to sleep mode and vice versa is negligible and is not taken into consideration. vi. Fraction of resources can be allocated to a VM.
The major components of P2RA approach are: (i) Services, (ii) Resource Allocation, (iii) Resource Scheduling, (iv) QoS Metric Data, and (v) Resource Description. Services: The end users can hire the services through cloud portal. This module stores information about type and number of services hired by the end users. Resource Allocation: This modules allocates resources to the services hired by the end users. A service is allocated to a resource that is most energy efficient. In order to find most suitable resource for service Cuckoo optimization is employed which discovers a resource employing Levy flight (LF). Allocation of service to the resource should result in minimal increase in power consumption while satisfying performance requirements. LF is a random walk that obeys Levy distribution. The reasons behind using LF for resource selection are: A random walk, consisting of series of consecutive random steps, is expressed as stochastic equation (1): here, x i (t) and x i (t+1) represents a resource at time t and t+1, respectively. D is the scaling factor for step size s.

Power Model
Power consumed by a resource is given by equation (2): static power consumption (SPC), P static , is due to leakage current and is independent of clock frequency and usage scenario. SPC can be reduced by switching idle resources to sleep mode [2]. However, dynamic power consumption (DPC), P dynamic , is due to circuit activity and it depends on resource utilization. Power consumption of resource, given by equation (3), increases linearly with its utilization [3].
where, P idle is the power consumption when the resource is idle, P max is the power consumption at 100% utilization, and P is the power consumption at utilization U H(0, 1) of the PM. Power consumption of a resource, when it is idle, is about 70% of the power consumed at full load [3]. Whereas, high utilization of a resource causes performance degradation because services running on it do not get sufficient resources [3]. So, a resource should not be operated at too low or very high utilization.

Fitness Function
The proposed resource allocation approach allows to group services hired by end users over the small number of resources and thus turning off those resources that are not used. P2RA approach considers performance as well as energy consumption while allocating resources to the service. The suitability of the resource r for service s is evaluated from fitness function f ( equation (4)). (4) where, is available processing power of resource r, is processing demand of service s, 'E s,r is energy contribution of service s on resource r, N r is energy affinity, is fraction of processing power allocated to service i on resource r, and 0 d J d 1 is a weight value to control the importance of energy contribution of service s.
gives performance affinity which is desired to be greater than 1 for better performance. 0 d T d 1 is used to control the importance between performance and energy. If T is set to 1 then performance is considered while allocating resources. However, if it is set to 0 importance is given to energy consumption. Energy affinity, N r , is set to energy consumption of resource r when it is idle which inclines P2RA towards resources with lower energy consumption in idle state.

Cuckoo Search
Cuckoo search is a nature inspired population based meta-heuristic algorithm developed by Xin-She Yang and Suash Deb in 2009 [24]. It is based on brood parasitic behavior of bird cuckoo. Cuckoo lay eggs in the nests of other host birds with amazing capability of selecting recently spawned nests. On the other hand, some host birds upon recognizing alien eggs either through them out or build new nests in other locations. Cuckoo reproduction process is simplified by three idealized rules: x Each cuckoo lays one egg at a time and dumps it in a randomly chosen nest. x Nests with high quality eggs are carried over to the next generations. x The host bird can discover the alien eggs with probability P a H (0, 1). Once an alien egg is discovered either the egg is thrown out or the nest is abandoned. A fraction P a of the n poor quality nests are replaced by new nests. In the proposed resource allocation approach, services are assumed eggs and resources are considered nests of host birds. Suppose, a set S of services and each service has some requirement attributes such as CPU, memory, and network bandwidth. The services are required to be mapped on set R of resources. Each resource r H R has some processing speed, memory and network bandwidth, respectively. Our aim is to allocates resources to services in such a way to reduce overall energy consumption without effecting performance of the services. The major steps followed for QoS and energy aware resource allocation to services are: a.

Resource Allocation using Cuckoo Optimization
Consider population (search space) of n resources. b.
Select a resource i from the search space using LF (equation (1)). c.
Randomly choose a resource j from search space of n resources. d.
Calculate fitness value f s,i of resource i for service s using equation (4). e.
Calculate fitness value f s,j of resource j for service s using equation (4). f.
If f s,i > f s,j then resource i is considered better than resource j. g.
Remove all those resources from the search space whose utilization is above upper green threshold (UGT). h.
Add resources, equal to number of removed resources, to the search space. i.
Rank the solutions and find current best solution. j.
Repeat step (c) through (i) until maximum iteration and the best solution does not change for three consecutive iterations. Iterations. k.
Instantiate the service on the best solution (resource).
The pseudo code for resource allocation using Cuckoo optimization is given in Algorithm 1. The steps (b) through (k) are repeated until all services are allocated resources or until maximum number of iterations have been performed. A resource is discovered that best suits the requirements of the service. Initially, a resource is selected from search space using LF (equation (1)). The selected resource represents a tentative solution for resource allocation problem. Our aim is to discover the best solution (resource) which results in minimum increase in energy consumption while satisfying QoS requirements of the service. Second resource is then selected randomly from the search space. Out of the two selected resources, a resource with lesser increase in power consumption is considered better. Then some of the resources, having utilization greater than UGT, are removed from population and equal number of new resources are added to the population. Resources removed from the population are not considered for resource allocation in subsequent iterations. A resource that is removed from population can be added to the population later on, when its utilization falls below lower green threshold (LGT). Population is a set of fittest n resources, out of which a resource is discovered for allocating resources to a job under consideration. Total number of resources in use are variable and changes with number of jobs and their resource requirements.

Performance Evaluation and Comparative Analysis
The proposed approach is implemented in CloudSim. CloudSim is a framework for modeling and simulation of cloud computing infrastructure and services [5]. For performance analysis, P2RA is compared with First Fit Decreasing (FFD). The specifications of four types of resources, which are simulated using PowerHost class of CloudSim, are as given in Table 1. Power models corresponding to these servers, available in CloudSim, are used to evaluate energy consumption. To conduct comparative analysis, P2RA and FFD are tested with services having different resource requirements. Simulation is repeated 25 times and in each simulation run, parameters are assigned values as per Table 2.   LGT 0.20 Lower Green Threshold limit Figure 2 shows the number of PMs used by FFD and P2RA to fulfill the requirements of given number of services. Number of services are varied from 200 to 1000 in step of 200. It is observed that number of resources used increases with number of resources. It has been experimentally established that P2RA uses 10.12% lesser number of resource than and FFD. Figure 3 shows total energy consumption comparison of FFD and P2RA. It has been observed that P2RA is approximately 12% more energy e_cient than FFD. Therefore, P2RA is more energy efficient and environment friendly. Figure 4 shows comparison of time taken by FFD and P2RA to map given number of services to resources. Number of services are varied from 200 to 1000. It is observed that P2RA takes more time to map given of services. This due to optimal allocation of resources. However, energy consumed during migration is negligible compared to energy saving achieved P2RA approach. Figure 5 shows the comparison of number of cold-spots observed for FFD and P2RA with respect to the number of services submitted for execution. A PM is defined as a cold-spot if its resource utilization is below LGT (=20%). The 20% limit is taken because average resource utilization of typical data center is between 20% and 30% [17]. The number of cold-spots portrays the extent of resource wastage. Lesser number of cold-spots createdin P2RA shows its ability to allocate the resources efficiently. Figure 6 shows the comparison of number of job rejections determined for FFD and P2RA as the number of services increases from 200 to 1000. A service is rejected when sufficient resources are not available for its execution. It depicts that number of services that are not admitted due to unavailability of resources. In case of P2RA lesser number of rejections are observed than FFD.

Conclusion and Future Scope
In this work, a bio-inspired resource allocation approach for enhancing energy efficiency and QoS of Clouds is introduced. The services are allocated resources in compliance with their demands. Cuckoo optimization is employed for optimal allocation of resources. The proposed resource allocation approach is implemented in CloudSim and tested with services having different QoS and resource requirements. The results have shown 12% saving of energy consumption In future, the proposed resource allocation methodology can be extended by identifying dependency among the services. The performance of proposed methodology can be evaluated on private cloud set up using any open source cloud environment such as OpenNebula, Eucalyptus, etc.