Shared Memory Buffer Mapping for VM Disk Writes
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In distributed computing systems, guest operating systems writing directly to real storage disks can lead to unsafe data duplication and inefficient buffer management, particularly when virtual machines are involved, due to long call chains and the need for multiple buffer copies.
Innovation Solution
A shared memory system is used to minimize buffer copying by allowing guest operating systems to write to virtual storage devices, with hypervisors translating these operations into real storage device operations using extents, reducing the need for buffer allocation and copying.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If guest operating systems write directly to real storage disks, then data transfer operations can be performed, but unsafe data duplication and inefficient buffer management occur due to long call chains and multiple buffer copies
Solution Approach 1:
The patent introduces a hypervisor as an intermediary layer between the guest operating system and the real storage disk. The hypervisor intercepts write operations from the guest OS, translates them into appropriate operations on the real storage device, and manages buffer allocation centrally. This intermediary approach eliminates the need for the guest OS to directly manage complex buffer copying operations while maintaining data safety through controlled access paths.
Solution Approach 2:
The patent implements a single-copy buffer management strategy where buffers are allocated once in the hypervisor's address space and shared with the guest OS through memory-mapped I/O. Instead of creating multiple copies of data in different buffers at various levels of the call chain, the same physical buffer is referenced by both the guest OS and the hypervisor, eliminating redundant copying operations while maintaining data integrity.
2Adaptability or versatility
If virtual machines are involved in storage operations, then system flexibility and isolation are improved, but buffer copying overhead increases due to translation layers
Solution Approach 1:
The patent merges the buffer management functionality into the hypervisor layer, combining the advantages of virtual machine isolation with efficient buffer handling. By consolidating buffer allocation and management in the hypervisor rather than having separate buffer chains in the guest OS and host OS, the system maintains virtual machine flexibility while reducing the number of copying operations required during data transfers.
Solution Approach 2:
The patent changes the dimensional approach to buffer management by transitioning from a multi-level hierarchical buffer structure (guest OS buffers → host OS buffers → device buffers) to a flat shared buffer model where a single buffer in the hypervisor's address space is accessed by both the guest OS and the storage device. This dimensional change eliminates intermediate copying steps while preserving virtual machine isolation through controlled access mechanisms.
3Reliability
If multiple buffer copies are used for safety, then data reliability is improved, but memory usage and copying overhead increase
Solution Approach 1:
The patent implements a single-copy buffer strategy where data is stored in a single buffer allocated in the hypervisor's address space. This single buffer is shared between the guest operating system and the host storage device through memory-mapped I/O and extent-based addressing. By eliminating redundant buffer copies, the system reduces memory consumption while maintaining data integrity through the hypervisor's controlled access and transaction management mechanisms.
Data Source
AI summary
Reducing buffer space that is reserved when a VM attempts to write to disk. A shared memory maintains stored information available to all VM's, allowing translation between accessible to RSD's, independent of how that VM's storage is divided into VSD's. When a guest OS writes to a VSD, an “extent”, designating a location in the shared memory and amount of data to be transferred, which can be passed directly from the guest OS, through each element involved in translating the operation into one or more operations on RSD's, keeping copying to a minimum. No substantial changes need be made to the guest OS.

