Shared Memory Migration for Virtual Machines
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Traditional virtual machine migration techniques are inefficient when dealing with shared memory spaces, leading to extended latency and downtime, as they fail to manage ongoing updates and maintain a consistent view of shared memory across virtual machines during migration.
Innovation Solution
Modified post-copy techniques are employed to migrate shared memory pages between hosts, allowing simultaneous migration of virtual machines and maintaining a consistent view of shared memory by designating migrated pages as not present on the source host, enabling seamless migration without stopping all virtual machines.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If traditional virtual machine migration techniques are used for shared memory spaces, then migration can be performed, but extended latency and downtime occur due to inability to manage ongoing updates and maintain consistent view
Solution Approach 1:
The shared memory space is segmented into individual memory pages that can be migrated independently. Each page is tracked separately with page table entries that indicate migration status, allowing selective migration of specific pages rather than requiring migration of the entire shared memory space at once.
Solution Approach 2:
The system performs preliminary actions by setting up page table entries on the destination host before actual memory page migration occurs. The page table entries are pre-configured to point to the source host, and migration is triggered on-demand when the destination host attempts to access a page, allowing migration to happen in the background without stopping virtual machines.
2Productivity
If traditional migration techniques are used, then virtual machines can be migrated, but all virtual machines must be stopped until migration completes
Solution Approach 1:
The system implements dynamic migration where the migration process adapts to ongoing virtual machine operations. Virtual machines continue to execute on the source host while pages are migrated in the background. The page table entries dynamically update to reflect migration status, allowing the system to transition from source to destination host without stopping virtual machines.
Solution Approach 2:
The hypervisor acts as an intermediary that manages the migration process between source and destination hosts. It intercepts memory access requests, determines whether pages have been migrated, and handles page faults by retrieving pages from the source host or allocating them from the destination host, allowing virtual machines to operate continuously during migration.
3Loss of time
If shared memory is migrated without modified post-copy techniques, then migration can proceed, but page faults increase and consistent view cannot be maintained
Solution Approach 1:
The system implements feedback mechanisms through page table entries that track the migration status of each memory page. When the destination host attempts to access a page, the page table entry provides feedback about whether the page is available locally or needs to be retrieved from the source host. This feedback loop allows the system to maintain consistency by ensuring pages are properly migrated before the virtual machine can access them on the destination host.
Data Source
AI summary
A hypervisor of a source host receives a request to migrate a group of virtual machines that provide network function virtualization support (NFV) from the source host to a destination host. The hypervisor of the source host determines that a first virtual machine of the group of virtual machines being migrated to the destination host shares a memory space on the source host with the group of virtual machines on the source host. Upon receiving a request from a second virtual machine of the group of virtual machines on the source host to access a first memory page of the shared memory space on the source host that has been migrated to the destination host, the hypervisor of the source host initiates migration of the second virtual machine to the destination host.


