计算机科学与探索 ›› 2017, Vol. 11 ›› Issue (1): 70-79.DOI: 10.3778/j.issn.1673-9418.1512055

• 高性能计算 • 上一篇    下一篇

云计算环境中虚拟机内存自适应调节算法研究

王德胜,张伟哲+,郝  萌,鲁刚钊,白恩慈   

  1. 哈尔滨工业大学 计算机科学与技术学院,哈尔滨 150001
  • 出版日期:2017-01-01 发布日期:2017-01-10

Research of Adaptive Virtual Machine Memory Scheduling Algorithm in Cloud Computing Environment

WANG Desheng, ZHANG Weizhe+, HAO Meng, LU Gangzhao, BAI Enci   

  1. School of Computer Science and Technology, Harbin Institute of Technology, Harbin 150001, China
  • Online:2017-01-01 Published:2017-01-10

摘要: Xen虚拟机自身的资源在创建之初已经固定,往往会因某些虚拟机内存不足而使用swap,使得虚拟机工作性能降低,而有的虚拟机内存比较空闲,使得整体虚拟机内存使用效率不高。之前已经有研究对虚拟机使用过程中的内存调度算法进行设计,但是经过推敲发现,之前内存调度算法由于没有考虑swap空间使用情况而导致整体内存调度不够高效。在前人算法研究基础上,提出了一个更加完善合理的内存调度算法,结合swap和内存使用情况一起调节虚拟机内存。算法仍然延续了Carl提出的空闲内存税概念加以设计,首先根据虚拟机内存和swap使用情况确定该次调节周期的调节范围,之后根据各个虚拟机的内存和swap空间使用情况计算虚拟机目标内存。对前后两种算法分别设计实验进行测试,验证了新算法的高效性。

关键词: Xen虚拟机, swap空间, 内存调度算法

Abstract: Resource of Xen virtual machines has been fixed when booted. However, some virtual machines have to use swap space because of the lack of memory while there is idle memory in other virtual machines, which reduces the usage efficiency of memory. There has been the design of memory scheduling algorithm among virtual machines in the previous research, but the scheduling algorithm is inefficient without the consideration of swap. On the foundation of the previous research, this paper puts forward a more reasonable scheduling algorithm that combines swap and the usage of memory to adjust the allocation of memory in virtual machines. The algorithm is also designed on the theory of the idle memory tax proposed by Carl. Firstly, the range of the adjustment will be settled based on the usage of memory and swap. Then the object memory will be calculated in the range. Compared with the previous algorithm, the improved algorithm has been proved to be more effective in experiments.

Key words: Xen virtual machine, swap space, memory scheduling algorithm