skip to main content
10.1145/3663408.3663423acmotherconferencesArticle/Chapter ViewAbstractPublication PagescommConference Proceedingsconference-collections
research-article

FlexMem: Proactive Memory Deduplication for Qcow2-Based VMs with Virtual Persistent Memory

Published: 03 August 2024 Publication History

Abstract

Virtualization-based cloud computing has gained popularity owing to its system-isolation security and near-native performance. However, a critical challenge for cloud computing arises from the presence of numerous redundant memory pages across independent virtual machines (VMs), significantly reducing memory efficiency. For instance, each VM typically loads data from its virtual disk into its memory without considering the existing data in other VMs’ memory. The state-of-the-art solution for addressing memory efficiency is kernel same-page merging (KSM), which performs memory deduplication by merging pages with identical data from different processes on the host. However, KSM operates reactively after memory redundancy has occurred, adding computational overhead due to periodic scanning, rendering it inefficient for cloud computing environments with high-density VMs.
In this paper, we propose FlexMem, a preliminary architecture designed to eliminate memory redundancy for VMs. FlexMem’s core is a virtual persistent memory (PMem) device with flexible backing specifications, which is designed to be memory-mapped (mmapped) to sparse and layered qcow2 images. By providing images to VMs in the form of FlexMem, and with the guest’s Direct Access (DAX) enabled, user programs within the guest gain direct access to identical images already cached in the host’s memory. This proactive approach eliminates memory redundancy before VMs’ startup. Our evaluation demonstrates that FlexMem significantly improves memory efficiency and the availability of VMs with reduced hardware costs, ultimately enhancing the competitiveness of cloud vendors.

References

[1]
2024. debian. (2024). https://www.debian.org/
[2]
2024. Executable and Linkable Format. (2024). https://en.wikipedia.org/wiki/Executable_and_Linkable_Format
[3]
2024. QEMU. (2024). https://www.qemu.org/
[4]
2024. rmap.c. (2024). https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/mm/rmap.c
[5]
2024. wordpress. (2024). https://hub.docker.com/_/wordpress
[6]
Alibaba Cloud. 2024. What is ECS? (2024). https://www.alibabacloud.com/help/en/elastic-compute-service/latest/what-is-ecs
[7]
Nadav Amit, Dan Tsafrir, and Assaf Schuster. 2014. Vswapper: A memory swapper for virtualized environments. Acm Sigplan Notices 49, 4 (2014), 349–366.
[8]
AWS. 2024. AWS Lambda. (2024). https://aws.amazon.com/lambda/features/
[9]
Alexandro Baldassin, Joao Barreto, Daniel Castro, and Paolo Romano. 2021. Persistent memory: A survey of programming support and implementations. ACM Computing Surveys (CSUR) 54, 7 (2021), 1–37.
[10]
Docker Inc.2024. docker. (2024). https://www.docker.com/
[11]
Google. 2024. Google Cloud Platform. (2024). https://cloud.google.com/products/compute
[12]
Intel Corporation. 2023. Intel® 64 and IA-32 Architectures Developer’s Manual: Vol. 3C. (2023). https://www.intel.com/content/www/us/en/architecture-and-technology/64-ia-32-architectures-software-developer-vol-3c-part-3-manual.html
[13]
Huiba Li, Yifan Yuan, Rui Du, Kai Ma, Lanzheng Liu, and Windsor Hsu. 2020. { DADI} :{ Block-Level} Image Service for Agile and Elastic Application Deployment. In 2020 USENIX Annual Technical Conference (USENIX ATC 20). 727–740.
[14]
Microsoft. 2024. Microsoft Azure. (2024). https://azure.microsoft.com/en-us/products/virtual-machines/
[15]
nvidia. 2024. nvidia/cuda. (2024). https://hub.docker.com/r/nvidia/cuda
[16]
The Apache HTTP Server Project. 2024. httpd. (2024). https://hub.docker.com/_/httpd
[17]
The kernel development community. 2024. Direct Access for files. (2024). https://docs.kernel.org/filesystems/dax.html
[18]
The kernel development community. 2024. Kernel Samepage Merging. (2024). https://docs.kernel.org/admin-guide/mm/ksm.html
[19]
The kernel development community. 2024. remap_file_pages() system call. (2024). https://www.kernel.org/doc/html/latest/mm/remap_file_pages.html
[20]
The QEMU Project Developers. 2024. virtio pmem. (2024). https://www.qemu.org/docs/master/system/devices/virtio-pmem.html
[21]
Peter Xu. 2020. KVM: Dirty ring interface. (2020). https://lwn.net/Articles/833784/

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Other conferences
APNet '24: Proceedings of the 8th Asia-Pacific Workshop on Networking
August 2024
230 pages
ISBN:9798400717581
DOI:10.1145/3663408
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than the author(s) must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected].

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 03 August 2024

Permissions

Request permissions for this article.

Check for updates

Qualifiers

  • Research-article
  • Research
  • Refereed limited

Conference

APNet 2024

Acceptance Rates

APNet '24 Paper Acceptance Rate 50 of 118 submissions, 42%;
Overall Acceptance Rate 50 of 118 submissions, 42%

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • 0
    Total Citations
  • 58
    Total Downloads
  • Downloads (Last 12 months)58
  • Downloads (Last 6 weeks)17
Reflects downloads up to 28 Feb 2025

Other Metrics

Citations

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

HTML Format

View this article in HTML Format.

HTML Format

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media