M22 - Performance Diagnosis
Performance Diagnosis
Check CPU, memory, and disk pressure more systematically so a slow system is diagnosed from evidence instead of guesses.
- Separate CPU pressure from memory pressure and disk pressure.
- Use a few basic tools to inspect each area.
- Avoid changing system settings before understanding the bottleneck.
Why This Matters
When a system feels slow, people often jump straight to a favorite explanation.
Real diagnosis is calmer than that. You want to ask:
- is the CPU busy?
- is memory tight or swapping?
- is disk activity the bottleneck?
Those questions lead to better decisions than guessing from one symptom.
1. CPU Is Only One Part of the Story
High CPU can matter, but it does not automatically explain everything.
A system can also feel slow because:
- memory pressure causes swapping or paging
- storage is busy and processes are waiting on I/O
- one stuck process is creating pressure for everything else
That is why you should not stop at one number.
2. Basic Memory Checks
Get-Counter “\Memory\Available MBytes” Get-Counter “\Memory\Pages/sec”
free -h cat /proc/meminfo | head -n 10
The goal is not to memorize every field. It is to notice whether free or available memory is very tight and whether swapping or paging activity seems significant.
3. Basic Disk and I/O Checks
If a process is waiting on storage, the system may feel slow even without dramatic CPU use.
Resource Monitor can be a practical visual starting point on Windows, especially for disk activity.
resmon
On Linux, top can hint at I/O wait, and tools such as iostat can provide a clearer storage picture if available.
top iostat -xz 1
A process can be “slow” because it is waiting, not because it is doing heavy compute.
4. Do Not Tune Blindly
It is tempting to jump to actions such as forcing kills, changing swap configuration, or installing tuning tools immediately.
That is rarely the right first move.
Better Performance Habit
Measure first. Identify which resource is under pressure. Change one thing only after you can explain why that change matches the evidence.
A Simple Diagnosis Sequence
- check overall system activity
- identify whether CPU, memory, or disk looks most stressed
- find the process or service contributing to that pressure
- only then decide whether to stop, tune, or defer work
That sequence is more valuable than memorizing lots of advanced counters.
What to Ignore for Now
- deep kernel scheduler details
- advanced storage tuning
- container and cgroup performance internals
The goal here is learning how not to guess.
Before You Move On
You are ready for the process lab when you can:
- name the three main resource areas to inspect
- explain why a slow system is not always a CPU problem
- describe a calm first-pass diagnosis sequence
Next, we apply this in a process troubleshooting scenario.