Linux CPU Isolation and NUMA Tuning: A Practical Guide to Exclusive Compute for Critical Workloads

Overview You’re running a high-frequency trading system online. P99 latency sits at 2ms normally, but occasionally spikes to 20ms. CPU usage isn’t high, memory is sufficient, network is fine. After investigation, you discover the CPU scheduler migrated a critical thread to another core, L3 cache missed entirely, and latency jumped 10x. This kind of problem can’t be solved by adding resources. The issue is “sharing” — all processes share CPU cores, the scheduler distributes freely, and nobody knows which threads are latency-sensitive....

July 13, 2026 · 18 mins · 3724 words · Xu Baojin

MySQL Performance Optimization: Slow Query Analysis and Index Tuning

Overview MySQL Performance Optimization: Slow Query Analysis and Index Tuning is an essential skill in SRE operations. In production environments, mastering these techniques can significantly improve system stability and operational efficiency. Why MySQL Performance Optimization Matters As systems grow in scale and complexity, traditional operations approaches struggle to meet the demands of modern distributed systems. MySQL Performance Optimization helps operations teams: Rapid Problem Resolution: Systematic tools and methods reduce troubleshooting time Improved System Visibility: Establish comprehensive monitoring and observability Proactive Fault Prevention: Identify and fix potential risks before they cause outages Resource Optimization: Allocate and schedule resources efficiently Core Concepts and Principles Basic Concepts The core of MySQL Performance Optimization lies in establishing standardized processes and automated toolchains....

October 13, 2025 · 3 mins · 571 words · XuBaojin

Linux Performance Analysis Powerhouse: BPF and the bcc Toolset

eBPF: The Kernel Programmability Revolution Traditional performance analysis tools fall into two categories: “overview” tools like top, vmstat, and iostat that tell you what’s happening at the system level but lack detail; and “tracing” tools like strace and gdb that show detail but incur massive overhead, making them impractical for production. eBPF (Extended Berkeley Packet Filter) changed everything. It allows you to run sandboxed programs in the kernel without modifying kernel source code or loading kernel modules....

November 13, 2024 · 9 mins · 1860 words · XuBaojin

Performance Engineering: A System Optimization Methodology from the SRE Perspective

Overview Performance issues are among the most common scenarios every SRE encounters: users report “it’s slow,” alerts say “P99 latency exceeds threshold,” monitoring shows “CPU is almost maxed.” But many teams handle performance issues with a “tune wherever it’s high” approach — add machines when CPU is high, add indexes when SQL is slow, add cache when latency is high. This symptomatic treatment may work short-term, but over time it makes the system increasingly complex, costs keep rising, and problems become harder to troubleshoot....

August 29, 2024 · 18 mins · 3738 words · XuBaojin

Disk I/O Performance Diagnosis and Optimization

Introduction Disk I/O is often the slowest link in the system performance chain. A single mechanical disk seek takes about 10ms, while memory access takes only about 100ns — a 100,000x difference. When business applications experience latency jitter or slow response times, the investigation inevitably points to the I/O subsystem. This article starts from the metrics system, combined with hands-on tool usage and production case studies, to build a reusable I/O diagnosis methodology....

March 27, 2024 · 8 mins · 1627 words · XuBaojin