Virtual Machine Live Migration with Dirty Write Flag
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In SR-IOV technology scenarios, live migration of virtual machines is hindered because the virtual machine manager cannot perceive data passing through virtual PCIE devices, preventing complete data migration during the process.
Innovation Solution
The implementation of a dirty write flag mechanism allows the virtual PCIE device to perform read and write operations, enabling the virtual machine manager to identify and migrate changed data, and includes message channel establishment between the virtual and physical PCIE devices for effective data transfer.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If SR-IOV technology is used to enable direct access between virtual machine and physical PCIE device, then VMM overhead is reduced and virtual exchange performance is improved, but the VMM cannot control data transmission behavior and cannot migrate device data during live migration
Solution Approach 1:
The patent introduces a VMM-mediated data transmission mechanism that acts as an intermediary between the virtual PCIE device and physical PCIE device. During live migration, the VMM intercepts and manages data transmission, enabling it to track and migrate device data while maintaining the SR-IOV direct access architecture for normal operations.
Solution Approach 2:
The system dynamically switches between two operational modes: normal mode where virtual PCIE devices directly access physical devices without VMM intervention, and migration mode where the VMM takes control of data transmission. This dynamic adaptability allows the system to optimize for performance during normal operation while enabling migration when needed.
2Speed
If virtual PCIE device directly accesses physical PCIE device without VMM involvement, then data transmission efficiency is improved, but data migration during virtual machine live migration cannot be implemented
Solution Approach 1:
The patent implements a feedback mechanism where the VMM monitors data transmission between virtual and physical PCIE devices during live migration. The VMM receives transmission status information and uses this feedback to track which data has been migrated and which remains, ensuring complete data migration while maintaining high transmission speeds through efficient batch operations.
3Measurement precision
If iterative pre-copy stage continuously copies changed memory data during virtual machine operation, then migration accuracy is improved, but the complexity of tracking data changes increases when SR-IOV devices are involved
Solution Approach 1:
The patent creates a unified data tracking mechanism that handles both traditional memory data and device data through a common framework. The VMM implements a universal tracking system that can identify and manage changes in both types of data, reducing overall system complexity by eliminating the need for separate tracking mechanisms.
Data Source
Figure 1~2
Figure 3~4
Figure 5
AI summary
Embodiments of the present invention provide a virtual machine live migration method and a server, to resolve a problem that live migration of a virtual machine cannot be implemented in an SR-IOV technology scenario. According to the virtual machine live migration method and the server in the embodiments of the present invention, by setting a dirty write flag, a virtual PCIE device of a to-be-migrated virtual machine performs at least one read and write operation on received data; a virtual machine manager of the to-be-migrated virtual machine can identify a change in the data and migrate changed data to a destination virtual machine, thereby resolving a problem in the prior art that data cannot be migrated during a virtual machine live migration process because the data passes through the virtual PCIE device but the virtual machine manager cannot perceive the data.