如何在CloudSim Plus中迁移Cloudlets?

huangapple go评论76阅读模式
英文:

How to migrate Cloudlets in CloudSim Plus?

问题

我想知道在CloudSim Plus中是否有一个功能可以允许Cloudlet的迁移。这意味着一个Cloudlet可以在虚拟机上执行,或者正在等待在虚拟机上执行,然后可以被发送到另一个虚拟机(可能位于另一个数据中心)来代替执行。在CloudSim Plus API中,我只看到了关于虚拟机迁移的分配策略,没有关于Cloudlet迁移的内容。

英文:

I wanted to know if there was a feature in CloudSim Plus that allows the migration of Cloudlets. This means that a Cloudlet could be executing on a VM or is waiting to be executed on a VM and can be sent to another VM (which may be in another data center) to be executed instead. In the CloudSim Plus API, I only see VM allocation policies for migration and nothing about Cloudlet migration.

答案1

得分: 1

CloudSim Plus没有任何方法来迁移Cloudlets。在真实的云计算环境中,我们不迁移Cloudlets,而是迁移容器或虚拟机(VMs)。这些VM/容器可以承载当前正在执行的Cloudlets,并可以迁移到另一个数据中心以继续执行。通过使用VM/容器,迁移Cloudlets就变得有意义。VMs/容器用于封装应用程序的依赖关系和配置。Cloudlet迁移是一项复杂的任务,无法自动完成。很难确定必须迁移的依赖关系和配置,以使应用程序(Cloudlet)能够执行。

根据CloudSim和CloudSim Plus的主要开发人员的说法:

但是,CloudSim Plus不支持容器抽象,并且在短期或中期内不打算支持。CloudSim 4包括容器支持,但是这个功能的实现方式(字面上是通过复制和粘贴整个包的类)使我们创建了独立的CloudSim Plus分支。

同时,了解在运行时将Cloudlet映射到Vm后,它是不能更改的,因为这将允许将Cloudlet迁移到另一个Vm,而这是CloudSim不允许的。作为替代方案,您可以尝试在运行时/动态地定义自己的策略,将传入的Cloudlet映射到Vms(选择要执行Cloudlet的Vms)。

您可以通过扩展DatacenterBrokerSimple类并更改defaultVmMapper()方法来实现这一点。如果您的策略无法将Cloudlet映射到Vm,它将调用DatacenterBrokerSimple中的defaultVmMapper

DatacenterBrokerSimple中的setVmMapper()方法允许您在运行时定义将Cloudlet映射到Vm的策略(它设置适当的映射方法)。该方法可用于在运行时更改策略。

要了解更多信息,请参阅CloudSim Plus的2个Google Group论坛:
1
2

英文:

CloudSim Plus doesn't have any way to migrate Cloudlets. In real cloud computing environments we don't migrate Cloudlets but containers ir VMs instead. This VM/container can host Cloudlets that are currently executing and can be migrated to another datacenter to continue execution. In this way (with VMs/containers) it makes sense to migrate Cloudlets. VMs/Containers are needed to encapsulate the dependencies and configurations of an application. Cloudlet migration is a complex task that can't be done automatically. It is hard to determine the dependencies and configurations that must be migrated to allow an application (Cloudlet) to execute.

According to the main developer of CloudSim and CloudSim Plus:

> However, CloudSim Plus doesn't support container abstration and it's not intended to support in the short or medium term. CloudSim 4
> includes container support, but the way this feature was implemented (literally by copying and pasting entire packages of classes) made us to create CloudSim Plus as an independent fork.

It's also important to understand when a Cloudlet is mapped to a Vm at runtime, it can't be changed because this would allow for Cloudlet migration to a different Vm which isn't allowed by CloudSim. As an alternative you could try defining your own policy to map incoming Cloudlets to Vms at run time/dynamically (chose Vms to execute a Cloudlet).

You can do this by extending the DatacenterBrokerSimple class and by changing the defaultVmMapper() method. If your policy fails to map a Cloudlet to a Vm, it will call the defaultVmMapper in DatacenterBrokerSimple.

The setVmMapper() method in DatacenterBrokerSimple lets you define a policy to map Cloudlets to a Vm at runtime (it sets the appropriate mapper method). This method can be used to change the policy at run time.

To learn more about this refer to the 2 CloudSim Plus Google Group Forums:
1,
2.

huangapple
  • 本文由 发表于 2020年3月16日 03:06:48
  • 转载请务必保留本文链接:https://go.coder-hub.com/60696604.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定