🔍🌩️ Unveiling the Enigma: 🔬🍲 Alibaba Cloud's ⚙️ CPU Co-location Technology!

🔍🌩️ Unveiling the Enigma: 🔬🍲 Alibaba Cloud's ⚙️ CPU Co-location Technology!

🚀OpenAnolis's CPU Co-location Technology Supercharges CPU Utilization on Koordinator💻

Play this article

This article dives into the realm of CPU Co-location, exploring its pivotal role in boosting CPU utilization.⚙️

What is CPU Co-location?🤔

CPU Co-location is like hosting a multi-talented party on a single machine🖥️, where diverse services share CPU resources to ramp up CPU utilization. This smart move cuts down on machine purchases and operational costs💰. However, the party guests include latency-sensitive online tasks like e-commerce🛍️, search🔎, and web services🌐. There are also offline tasks, who are less bothered about time but more into munching resources for computation or batch processing. So, to keep the party going without the offline tasks overshadowing the online ones, CPU Co-location technology comes to the rescue.🦸‍♂️

Kernel CPU Co-location Technology🔧

Enter the operating system scheduler, which tactfully allocates CPU resources based on the type of tasks. OpenAnolis's triumvirate of native technologies provides the Koordinator community with robust technical support for CPU Co-location. These are:

  • Group Identity Co-location Technology👥

  • Plugsched Scheduler Live Upgrade Technology🔄

  • CPU Co-location Plug-In Products🔌

2.1 OpenAnolis Group Identity Technology🆔

OpenAnolis's Group Identity tech empowers the operating system kernel with CPU Co-location ability. It's like the secret sauce in Alibaba Cloud Linux 2/3 and Anolis 7/8 OS distributions. This tech introduces a new run queue to the original CFS to distinguish the party-goers (online and offline tasks) and politely escorts offline tasks to prevent any intrusion on the peer CPU (hyper-threading architecture).🏃‍♂️

2.2 OpenAnolis CPU Co-location Plug-in🔌

On the Koordinator standalone operating systems' stage, we primarily have Alinux 2/3 and CentOS 7.9. For Alinux 2/3, the CPU Co-location technology springs from OpenAnolis's Group Identity. But for CentOS 7.9, it currently lacks the CPU Co-location feature. But, fear not! OpenAnolis developers have crafted a solution - a scheduler plug-in package with CPU Co-location tech, empowered by the Plugsched scheduler live upgrade technology. The plug-in encapsulates Alibaba Cloud's early (2017) CPU Co-location technology bvt + noise clean and can be seamlessly installed to CentOS 7.9 without any downtime or business migration.👩‍💻

2.2.1 Plugsched🔄

OpenAnolis generously provides the Plugsched SDK scheduler live upgrade development tool. It smartly disconnects the scheduler from the Linux kernel to form an independent module, transplants CPU Co-location tech to the scheduler module to create a scheduler plug-in, and installs the plug-in in the running system, so you can benefit from the CPU Co-location tech.

Open-Source Plugsched: https://gitee.com/anolis/plugsched🔗

2.2.2 Testing Group Identity🎯

The Group Identity Co-location tech was put to test in the offline best practice manual of the Koordinator community. The online task was the swift Nginx service, and the offline task was the ffmpeg video transcoding, busy crunching numbers.

Test results (unit: ms):

BaselineControl GroupExperimental Group
RT-P900.5330.574 (+7.7%)0.548 (+2.8%)
RT-P990.931.58ms (+70%)0.96 (+3.2%)
CPU%29.6%85.6%64.8%

2.2.3 Test on CPU Co-location Plug-In🎯

A similar test was conducted on the scheduler plug-in to compare its performance with the Group Identity.

Test results (unit: ms):

BaselineControl GroupExperimental Group
RT-P900.4440.575 (+29.50)0.504 (+13.51%)
RT-P990.7061.7 (+140.79)0.88 (+24.64%)
CPU%25.15%71.7%49.15%

2.3 Group Identity Outshines🌟

The test results reveal that the Group Identity is a star performer⭐, significantly outshining the bvt + noise clean plug-in. It's excellent at minimizing the impact of offline tasks on online tasks and at amplifying CPU utilization.💯

Conclusion🎬

Calling all technicians, open-source enthusiasts, avid readers, and users! You're all invited to experience the marvel of CPU Co-location technology, Group Identity, and Plugsched, introduced by OpenAnolis.🎁

Cloud Kernel SIG Homepage: https://openanolis.cn/sig/Cloud-Kernel🔗

Did you find this article valuable?

Support Aditya Katira by becoming a sponsor. Any amount is appreciated!