cloudsim icon indicating copy to clipboard operation
cloudsim copied to clipboard

Migration is not happening in PlanetLab Examples any specific reason?

Open Riman-M opened this issue 1 year ago • 9 comments

Experiment name: 20110303_lrr_mu_1.2 Number of hosts: 800 Number of VMs: 1052 Total simulation time: 600.01 sec Energy consumption: 5.87 kWh Number of VM migrations: 0 SLA: NaN% SLA perf degradation due to migration: NaN% SLA time per active host: 0.00% Overall SLA violation: NaN% Average SLA violation: 0.00% Number of host shutdowns: 800 Mean time before a host shutdown: 591.01 sec StDev time before a host shutdown: 51.21 sec Mean time before a VM migration: NaN sec StDev time before a VM migration: NaN sec Execution time - VM selection mean: 0.00000 sec Execution time - VM selection stDev: 0.00000 sec Execution time - host selection mean: 0.00200 sec Execution time - host selection stDev: 0.00141 sec Execution time - VM reallocation mean: 0.00050 sec Execution time - VM reallocation stDev: 0.00071 sec Execution time - total mean: 0.00600 sec Execution time - total stDev: 0.00283 sec

Riman-M avatar May 01 '25 05:05 Riman-M

Neither are they happening on the Random Workload, seems like an issue in the Power module

============================================= Experiment name: random_iqr_mu_1.5 Number of hosts: 50 Number of VMs: 50 Total simulation time: 600.01 sec Energy consumption: 0.38 kWh Number of VM migrations: 0 SLA: NaN% SLA perf degradation due to migration: NaN% SLA time per active host: 0.00% Overall SLA violation: NaN% Average SLA violation: 0.00% Number of host shutdowns: 50 Mean time before a host shutdown: 594.01 sec StDev time before a host shutdown: 42.43 sec Mean time before a VM migration: NaN sec StDev time before a VM migration: NaN sec Execution time - VM selection mean: 0.00000 sec Execution time - VM selection stDev: 0.00000 sec Execution time - host selection mean: 0.00000 sec Execution time - host selection stDev: 0.00000 sec Execution time - VM reallocation mean: 0.00050 sec Execution time - VM reallocation stDev: 0.00071 sec Execution time - total mean: 0.00150 sec Execution time - total stDev: 0.00071 sec

codaphobe avatar May 08 '25 14:05 codaphobe

I'll have a look into it, but I believe the migration feature was not working in CloudSim 6G as well

deRemo avatar May 11 '25 20:05 deRemo

So should we use Cloudsim 5G for that?

Riman-M avatar May 16 '25 06:05 Riman-M

I've tried cloudsim 7 pre that's working fine.

codaphobe avatar May 16 '25 11:05 codaphobe

@codaphobe I can give it a look, unless some of you is interested in helping on that. Can you tell me which example did you try>

deRemo avatar May 16 '25 11:05 deRemo

@codaphobe I can give it a look, unless some of you is interested in helping on that. Can you tell me which example did you try>

All examples has same issue. planetlab and random both

Riman-M avatar May 16 '25 14:05 Riman-M

@codaphobe I can give it a look, unless some of you is interested in helping on that. Can you tell me which example did you try>

I am open to help but i just found a quick solution to make migrations happen by removing the following condition from the method getCompletedVms() from the HostDynamicWorkload class :

if (guest instanceof VirtualEntity vm && vm.getNumberOfGuests()==0) {
				vmsToRemove.add(vm);
			}

getCompletedVms() is called from PoweDatacenter class after all the Power data has been calculated to remove unused Vm's?

I did not understand why this condition was written since all Vms as instance of VirtualEntity and the other condition is always True unless there are nested Vm's. I could not find the commit where this part of the code was introduced to know why it was written.

codaphobe avatar May 18 '25 14:05 codaphobe

Hi @codaphobe, sorry for the late reply: it was added in commit cb406da to support nested Vms.. Much like the old ContainerHostDynamicWorkload class used to do for containers - that's from where I took inspiration. However, the latter class may have been bugged to begin with :p Feel free to open a PR with your findings

deRemo avatar Jun 03 '25 17:06 deRemo

@Riman-M, Riman da english ei boli. Is it working now with you? If not let me know.

Astabol avatar Aug 05 '25 16:08 Astabol