Dynamic VCPU Migration for Real-Time CPU Sharing
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Conventional load balancing algorithms fail to effectively manage the sharing of physical CPUs between real-time and server software, leading to performance skewing due to the lack of consideration for real-time activity, resulting in inefficient resource utilization and computing time increases.
Innovation Solution
Implement a dynamic load balancing mechanism that migrates virtual CPUs between physical CPUs based on calculated load thresholds and migration criteria, ensuring that overloaded CPUs are balanced by transferring VCPUs to underloaded ones, while maintaining transparency for SMP guests and avoiding unnecessary migrations.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Productivity
If conventional load balancing algorithms are used to spread guest tasks between CPUs, then computing time is decreased and resource utilization is improved, but real-time activity on shared CPUs is not considered, causing performance skewing
Solution Approach 1:
The system segments the load balancing decision-making process by separating real-time task handling from generic server task handling. The real-time scheduler and SMP load balancer operate as distinct segments, each managing specific types of tasks according to their unique requirements, thereby preventing real-time activity from being skewed by generic load balancing decisions
Solution Approach 2:
The patent introduces an intermediary mechanism where the real-time scheduler on the shared CPU communicates task status and timing constraints to the SMP load balancer. This intermediary communication allows the load balancer to make informed decisions that consider real-time requirements while still achieving load balancing across the system
2Device complexity
If static mapping between virtual and physical CPUs is used, then system simplicity is maintained, but load balancing efficiency is reduced
Solution Approach 1:
The system implements dynamic VCPU to physical CPU mapping where the correspondence between virtual and physical CPUs can change over time based on system conditions. The load balancer continuously monitors CPU utilization and reassigns VCPUs to different physical CPUs as needed, transforming the static mapping into a dynamic one that adapts to changing workloads
Solution Approach 2:
The patent changes the parameter of VCPU mapping from fixed to variable, allowing the mapping relationships to be adjusted based on load conditions. By making the mapping parameter changeable, the system achieves improved load balancing efficiency while maintaining manageable complexity through automated management
3Productivity
If load balancing migrates VCPUs between physical CPUs, then CPU load is balanced and resource utilization is optimized, but migration overhead and system complexity increase
Solution Approach 1:
The load balancer implements self-service by automatically monitoring CPU utilization, identifying imbalanced conditions, and executing VCPU migrations without external intervention. The system serves itself by having the load balancer continuously adjust VCPU placements based on current system state, reducing the need for complex external management mechanisms
Data Source
Figure 1
Figure 2
Figure 3
AI summary
In a preferred embodiment, the present invention provides a method of load balancing in a data processing system comprising a plurality of physical CPUs and a plurality of virtual CPUs, the method comprising: mapping one or more virtual CPUs to each of said physical CPUs; and dynamically adapting the mapping depending on the load of said physical CPUs.