Research Article

An Energy-Efficient Strategy and Secure VM Placement Algorithm in Cloud Computing

Algorithm 4

VMs free.
Input: ACTH = {acth1, acth2, …, acthk} ⟶ Hosts which are in active state,
ACTV = {actv11, actv12, …, actv21, actv22, …, actv2p} ⟶ VMs which are in active state.
Output: ACTV Updated.
(1)for each host in active state acthi ∈ ACTH then do
(2) for each VM actvij ∈ acthi then do
(3)  if actvij in idle state then
(4)   Deallocate actvij resources to acthi
(5)  end if loop
(6) end for loop
(7)end for loop