25
Energy Efficient in Cloud Computing Christoph Aschberger Franziska Halbrainer May 24, 2013 1 of 25

Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

  • Upload
    others

  • View
    2

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Energy Efficient in Cloud Computing

Christoph AschbergerFranziska Halbrainer

May 24, 2013

1 of 25

Page 2: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Introduction

• Energy consumption by Google 2011: 2,675,898 MWh.• We found that we use roughly as much electricity globally as

220,000 people, based on electricity use per capita in the US.http://www.google.com/intl/en/green/bigpicture/references.html

An aisle in a Google serverfarmhttp://www.google.com/about/datacenters/gallery/#/tech/12

2 of 25

Page 3: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Modelling of Energy Consumption

• Identify the components that consume energy

• How much energy they consume on different workloads

• The energy consumption of a cloud over a time span can be calculated asshown in [8]:

ECloud =

∫ t2

t1

ENodes + ESwitches + EStorages + EOthersdt (1)

ENode = ECPU + EMemory + EDisk + EMainboard + ENIC (2)

ESwitch = EChassis + ELinecards + EPorts (3)

EStorage = ENASServer + EStorageController + EDiskArray (4)

3 of 25

Page 4: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

How to save energy

• Use energy efficient hardware

• No energy needed if a machine is not running

• Fewer machines running ⇒ less energy usage

• Always run only as many machines as currently needed?

• Algorithms needed to decide which machines should run

4 of 25

Page 5: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Cloud Model

• Task vs VM

• Task:◦ Many requirements are known in advance (CPU, duration)◦ Will not suddenly stop◦ Will not suddenly need more

• VM:◦ Only upper bounds are known◦ Can need less resources than agreed on◦ Resource usage might change suddenly◦ Lifetime is not known◦ Can stop suddenly or run indefinitely◦ Can migrate from one machine to another

5 of 25

Page 6: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Dynamic Voltage Frequency Scaling [6]

• Using a near-optimal list-scheduling heuristic for mapping interdependenttasks to resources

• The energy usage E of a task E = k · v2 · f ·∆t

• Where k is a device dependant constant, v is the voltage, f is thefrequency and ∆t is the execution time.

• Lower voltage means lower max frequency

• Lower voltage means less energy consumption

• Earliest start time: time when all predecessors are finished.

• Latest finish time: minimum of latest start time of all successors.

• Slack time: difference between this timespan and the execution time athighest frequency.

• Slack time can be used to slow the computation down and save energy.

6 of 25

Page 7: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Dynamic Voltage Frequency Scaling [6]

• In a loop start with the task with the latest latest finish time◦ Find set S: tasks on the same processor with overlapping execution times◦ Texec(S): sum of all execution times of tasks in this set◦ Ttotal(S): earliest earliest start time - latest latest finish time

◦ fglobal(task) = fmax max(Texec(task)

Texec(task)+Tslack(task), Texec (S)Ttotal (S)

)

scheduling task t3 on r0 [7]

7 of 25

Page 8: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Task consolidation [7]

• Not running one task alone, but more tasks at once on the same machine• Two different heuristics are suggested for consolidation

Algorithm 1 Find machine to run task tj on

Input: A task tj and a set R of r cloud resourcesOutput: A task resource match

Let r∗ = ∅2: for ∀riεR do

Compute the cost function value fi,j of tj on ri4: if fi,j > f∗,j then

Let r∗ = ri6: Let f∗,j = fi,j

end if8: end for

Assign tj on r∗

8 of 25

Page 9: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Task consolidation [7]

• ECTC (Energy-conscious task consolidation)• fi,j = pmin · (τ0 − τ1)• τ0 :total running time of task τ1: time at which task runs alone on

machine• pmin: energy consumption of idle machine• Worst case: τ0 = τ1 than fi,j = 0• Best case: τ1 = 0

scheduling task t3 on r1 [7]

9 of 25

Page 10: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Task consolidation [7]

• MaxUtil

• fi,j =∑τ0

τ=1 Ui

τ0

• Ui is Utilisation of a resource ri at a given time

• Best case: when utilisation of period is max

• Worst case: when there are no other task running on this machine

scheduling task t3 on r0 [7]

10 of 25

Page 11: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration

• Possibility: a VM does not need the agreed performance

• Chance: allocate VMs on PMs according to used performance

• Migrate: VM needs more than available on its PM → move to other PM

• (Live) migration however comes with costs:◦ Performance of a VM during migration may be degraded◦ Additional energy is needed as the VM is allocated on two PMs◦ The network load is increased

• Trade off:◦ Using as few PMs as possible and risking migrating often◦ Minimizing the number of migrations at the cost of powering more PMs.

11 of 25

Page 12: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration [3]

VM selection for migration

• With single fixed Threshold◦ Define upper utilization threshold for hosts◦ Place VMs on host as long as the threshold is not violated◦ Reserve resources to avoid immediate migration if demand increases

• With upper and lower Threshold◦ Keep the utilization between thresholds by migrating◦ Three different VM selection policies• Minimization of Migrations - migrate least number of VMs• Highest Potential Growth - migrate VMs with lowest usage of CPU relatively

to requested• Random Choice - choose necessary number of VMs randomly

12 of 25

Page 13: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration [3]

• Dynamic Utilization Thresholds◦ Assume utilization created by VM is a random variable uj◦ CPU utilization of a host represented as Ui as sum of utilizations◦ Assume distributions of VMs are different◦ Distribution of the host’s utilization is normal and can be modeled by the

t-distribution◦ With the inverse cumulative probability function an interval of utilization

which will be reached with low probability can be determined◦ With this information the upper threshold can be set◦ The lower threshold is a global value across all hosts◦ It aims to identify the hosts with lower utilization than the average

13 of 25

Page 14: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration [3]

VM Placement

• Modified Best Fit Decreasing to consider power usage

• Sort VMs by decreasing order of CPU utilization

• Allocate a VM to the host with the least increase of power consumption

• This maximizes the utilization of power efficient hosts

14 of 25

Page 15: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration [4]

• Knowledgebase:◦ Knows all about VMs, PMs,◦ Current memory/CPU utilization, agreed SLAs◦ Makes decision upon rules

• Every resource has 2 Thresholds

• Span between Threshold must be big enough to prevent oscilatingbehavior

15 of 25

Page 16: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

VM migration [4]

• Alloc / Realloc Algorithm◦ First Fit: Realloc half of most loaded and all of least loaded◦ Monte Carlo:• Alloc in Round Robin• Realloc calculates cost for current alloc and for random sets

◦ Vector Packing:• Sorts VMs based on resource utilization, highest first• Takes a VM from the list and tries to put it on the most energy efficient

machine• Realloc: load balances some VMs on most loaded PMs that will not be empty

in future iterations

• PM Power Management◦ Power off: Number of PMs to switch off =bNumberofemptyPMs

ac

◦ Turns off PMs in an exponential manner◦ Power on: if average utilization of a resource exceeds its threshold → power

on as many PMs as necessary

16 of 25

Page 17: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Decentralized VM migration [9]

• A homogeneous hardware basis is assumed◦ Each host is capable of holding the same amount of same-sized virtual

machines◦ Protocol can easily be extended to handle heterogeneous hardware and VMs

• Gossip protocol

• Two threads running on each physical machine◦ The active thread◦ The passive thread

17 of 25

Page 18: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Decentralized VM migration [9]

Algorithm 2 Procedure ACTIVE THREAD

loop2: Wait ∆

for all j ε GetNeighbors(i) do4: Send (Hi ) to j

Receive (H ′i ) from j6: Hi ← H ′i

end for8: end loop

18 of 25

Page 19: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Decentralized VM migration [9]

Algorithm 3 Procedure PASSIVE THREAD

loop2: Wait for message Hj from j

if Hi ≥ Hj then4: D ← min(Hj ,C − Hi )

Send (Hj − D) to j6: Hi ← Hi + D

else8: D ← min(Hi ,C − Hj)

Send (Hj + D) to j10: Hi ← Hi − D

end if12: end loop

19 of 25

Page 20: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Artificial Intelligence Approach [5]

• MultiDimensional Bin Packing Problem

• Goal: to use as few machines as possible

• Ant colony as model to optimize workload placement◦ Ants communicate through pheromones◦ Pheromone is emitted by an ant◦ Pheromone evaporates after some time◦ Shortest path to food source has highest concentration of pheromones◦ Ants tend to prefer paths with higher concentration

• Technical implementation:◦ Artificial ants act as multi-agent system◦ Construct a complex solution based on indirect low-level communication

20 of 25

Page 21: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Artificial Intelligence Approach [5]

• Ant knows about all running VMs and all PMs.

• Ant allocates a VM on a PM based on a probabilistic decision rule◦ Based on current pheromone level◦ Heuristic information

• Pheromone level is calculated◦ Decreasing the old pheromone level by a factor◦ Adding pheromones from the best ant in this round

• Pheromone concentration must lay between thresholds to prevent earlystagnation

• Termination: restricting the algorithm to a fixed amount of iterations

• Output is chosen to be the global best solution so far

21 of 25

Page 22: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

Conclusion

• There is no standard test set all authors used

• Some are more detailed than others

• In the presented papers only node power usage is considered

22 of 25

Page 23: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

References (1)

[1] http://www.google.com/about/datacenters/gallery/#/tech/12.

[2] http://www.google.com/intl/en/green/bigpicture/references.html.

[3] Anton Beloglazov and Rajkumar Buyya.Adaptive threshold-based approach for energy-efficient consolidation ofvirtual machines in cloud data centers.In Proceedings of the 8th International Workshop on Middleware forGrids, Clouds and e-Science, MGC ’10, pages 4:1–4:6, New York, NY,USA, 2010. ACM.

[4] Damien Borgetto, Michael Maurer, Georges Da-Costa, Jean-MarcPierson, and Ivona Brandic.Energy-efficient and SLA-aware management of IaaS clouds.In Proceedings of the 3rd International Conference on Future EnergySystems: Where Energy, Computing and Communication Meet, e-Energy’12, pages 25:1–25:10, New York, NY, USA, 2012. ACM.

23 of 25

Page 24: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

References (2)

[5] Eugen Feller, Louis Rilling, and Christine Morin.Energy-Aware Ant Colony Based Workload Placement in Clouds.In Proceedings of the 2011 IEEE/ACM 12th International Conference onGrid Computing, GRID ’11, pages 26–33, Washington, DC, USA, 2011.IEEE Computer Society.

[6] Qingjia Huang, Sen Su, Jian Li, Peng Xu, Kai Shuang, and Xiao Huang.Enhanced Energy-Efficient Scheduling for Parallel Applications in Cloud.In Proceedings of the 2012 12th IEEE/ACM International Symposium onCluster, Cloud and Grid Computing (ccgrid 2012), CCGRID ’12, pages781–786, Washington, DC, USA, 2012. IEEE Computer Society.

[7] YoungChoon Lee and AlbertY. Zomaya.Energy efficient utilization of resources in cloud computing systems.The Journal of Supercomputing, 60(2):268–280.

24 of 25

Page 25: Energy Efficient in Cloud Computing...Adaptive threshold-based approach for energy-e cient consolidation of virtual machines in cloud data centers. In Proceedings of the 8th International

References (3)

[8] Liang Luo, Wenjun Wu, Dichen Di, Fei Zhang, Yizhou Yan, andYaokuan Mao.A resource scheduling algorithm of cloud computing based on energyefficient optimization methods.In Green Computing Conference (IGCC), 2012 International, pages 1–6,2012.

[9] M. Marzolla, O. Babaoglu, and F. Panzieri.Server consolidation in Clouds through gossiping.In World of Wireless, Mobile and Multimedia Networks (WoWMoM),2011 IEEE International Symposium on a, pages 1–6, 2011.

25 of 25