虚拟机动态迁移策略优化研究
2016-01-18庞峰顾炜江
庞峰++顾炜江



摘要: Pre-Copy算法策略采用仅仅比较相邻两轮传递页位图和跳过页位图的方式来判断内存页是否需要复制传递。优化之后的Pre-Copy算法策略是根据所有记录的内存页修改次数来判定脏页,当达到某个定义的脏页的阈值时,即进行复制重传。实验结果表明,在高CPU负载、高内存负载和高网络负载的情况下,Pre-Copy算法的优化策略,缩短了虚拟机动态迁移的停机时间和总迁移时间,提高了虚拟机动态迁移的效率。
关键词:虚拟机;动态迁移;策略;优化
中图分类号:TP391 文献标识码:A 文章编号:1009-3044(2015)33-0149-03
Optimization of Live Migration Strategy for Virtual Machine
PANG Feng,GU Wei-jiang
(Nanjing Forestry University, Information Centre, Nanjing 210037, China;)
Abstract: Pre-Copy algorithm only two rounds of adjacent transfer bitmap and skip pages bitmap way to judge whether memory pages need to be copied. After optimization of the Pre - Copy algorithm based on all the records to judge dirty pages, the number of pages to modify when reach a certain threshold of dirty pages defined, namely to reproduce the retransmission. The experimental results show that the high CPU load, memory load and high network load conditions, the adaptive optimization algorithm of the Pre - Copy, shortens the virtual machine live migration of downtime and total migration time, improve the efficiency of the virtual machine live migration.
Key words: virtualization; live migration; strategy; optimization
1 概述
虚拟化技术作为云计算的核心技术,为满足用户按需访问云上数据和服务提供了可能。通过虚拟化技术部署的虚拟机与传统计算机相比,虚拟机具有良好的灵活性,它能够在不间断服务运行的情景下完成服务实时动态迁移。主流虚拟化平台,如VMware、KVM及Xen等,都提供虚拟机动态迁移功能,已经被应用于局域网环境中跨物理主机的虚拟机迁移 [1][2],但是高CPU负载、高内存负载和高网络负载等条件下的虚拟机进行迁移的效果并不是很理想。本研究对Pre-Copy算法策略进行了优化,并进行了实验验证。
2 Pre-Copy算法迁移策略
Pre-Copy算法是Push和Stop-and-Copy相结合的一种内存迁移方案 [3]。该算法复制传递策略如图1所示。
Pre-Copy算法的局限性在于高负载情况下,Pre-Copy算法会造成很大的服务器系统开销,甚至会导致延长停机时间和总迁移时间,这主要是由于处在高负载运行状态下需要不断进行被修改内存页的复制传递,达到虚拟机系统运行能力的上限才会停止内存页的复制传递过程进入停机复制阶段。……
