DuVisor:通过委托虚拟化实现的用户级虚拟机管理程序
DuVisor: a User-level Hypervisor Through Delegated Virtualization
摘要:
当今主流的虚拟化系统由两个协作组件组成:访问虚拟化硬件的内核驻留驱动程序和提供VM管理和I/O虚拟化的用户级帮助进程。然而,这种虚拟化架构在安全性(大的攻击面)和性能方面都存在固有的问题。虽然有很长的工作线程试图通过将函数卸载到用户模式来最小化内核驻留驱动程序,但它们面临着安全性和性能之间的基本权衡:更多的卸载可能会减少内核攻击面,但会增加助手进程和驱动程序之间的运行时环交叉,从而增加性能成本。本文探讨了一种新的设计称为委托虚拟化,它完全分离的控制平面(内核驱动程序)的数据平面(助手进程),从而消除了内核驱动程序的运行时干预。由此产生的用户级管理程序称为DuVisor,可以处理所有VM操作,而不会在内核驱动程序完成初始化后陷入内核。DuVisor通过一个新的委托虚拟化扩展来改造现有的硬件虚拟化支持,以直接处理VM退出、配置虚拟化寄存器、管理用户模式下的第2阶段页表和虚拟设备。我们在开源RISC-V CPU上实现了硬件扩展,并在硬件上构建了基于Rust的虚拟机管理程序。在FireSim上的测试表明,DuVisor在各种实际应用中的性能比KVM高出47.96%,并显著减少了攻击面。
英文摘要:
Today's mainstream virtualization systems comprise of two cooperative components: a kernel-resident driver that accesses virtualization hardware and a user-level helper process that provides VM management and I/O virtualization. However, this virtualization architecture has intrinsic issues in both security (a large attack surface) and performance. While there is a long thread of work trying to minimize the kernel-resident driver by offloading functions to user mode, they face a fundamental tradeoff between security and performance: more offloading may reduce the kernel attack surface, yet increase the runtime ring crossings between the helper process and the driver, and thus more performance cost. This paper explores a new design called delegated virtualization, which completely separates the control plane (the kernel driver) from the data plane (the helper process) and thus eliminates the kernel driver from runtime intervention. The resulting user-level hypervisor, called DuVisor, can handle all VM operations without trapping into the kernel once the kernel driver has done the initialization. DuVisor retrofits existing hardware virtualization support with a new delegated virtualization extension to directly handle VM exits, configure virtualization registers, manage the stage-2 page table and virtual devices in user mode. We have implemented the hardware extension on an open-source RISC-V CPU and built a Rust-based hypervisor atop the hardware. Evaluation on FireSim shows that DuVisor outperforms KVM by up to 47.96\% in a variety of real-world applications and significantly reduces the attack surface.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。