Skip to content

Commit 1c7545c

Browse files
committed
Add runbooks for GuestVCPUQueueHigh alerts
This PR adds runbooks for GuestVCPUQueueHighWarning and GuestVCPUQueueHighCritical alerts. Signed-off-by: Shirly Radco <sradco@redhat.com>
1 parent ca6ea5d commit 1c7545c

2 files changed

Lines changed: 92 additions & 0 deletions

File tree

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
# GuestVCPUQueueHighCritical
2+
3+
## Meaning
4+
A VirtualMachineInstance (VMI) reported a **guest CPU run‑queue length greater than 20** runnable or
5+
uninterruptible threads within the last scrape window (120s), indicating severe CPU contention.
6+
7+
## Impact
8+
* Sustained backlog; high latency and throughput degradation are likely.
9+
* Risk of timeouts, watchdog resets, or I/O amplification.
10+
11+
## Diagnosis
12+
Follow the below steps with extra focus on:
13+
* **Duration** – How long is the queue > 20
14+
* **Host saturation** – if node CPU is also > 90 %, migrate other VMs or mark the node as unschedulable
15+
so that no new Pods/VMs are placed thereon it.
16+
17+
1. **Confirm queue length**
18+
```promql
19+
kubevirt_vmi_guest_vcpu_queue{namespace="$NS",name="$VM"}
20+
```
21+
2. **Check host CPU usage**
22+
```promql
23+
rate(kubevirt_vmi_cpu_usage_seconds_total{namespace="$NS",name="$VM"}[2m])
24+
```
25+
3. **Inspect guest processes**
26+
`virtctl console <vm>``top -H` or `pidstat -u 1`
27+
4. **Verify vCPU allocation**
28+
```bash
29+
oc get vmi $VM -ojsonpath='{.spec.domain.cpu}'
30+
```
31+
32+
## Mitigation
33+
| Horizon | Action |
34+
|---------|--------|
35+
| Immediate | **Prioritise**: live‑migrate VM; hot‑plug vCPUs; stop or throttle runaway processes. |
36+
| Short term | Permanently raise vCPU allocation or split workload across VMs. |
37+
| Long term | Adjust scheduling/placement policies; add autoscaling tied to queue length. |
38+
39+
<!--USstart-->
40+
If you cannot resolve the issue, see the following resources:
41+
42+
- [OKD Help](https://www.okd.io/help/)
43+
- [#virtualization Slack channel](https://kubernetes.slack.com/channels/virtualization)
44+
<!--USend-->
45+
46+
<!--DS: If you cannot resolve the issue, log in to the
47+
[Customer Portal](https://access.redhat.com) and open a support case,
48+
attaching the artifacts gathered during the diagnosis procedure.-->
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
# GuestVCPUQueueHighWarning
2+
3+
## Meaning
4+
A VirtualMachineInstance (VMI) reported a **guest CPU run‑queue length greater than 10** runnable or \
5+
uninterruptible threads within the most‑recent scrape window (120s).
6+
The run‑queue length is derived from `guest_load_1m – vCPU_count`.
7+
8+
## Impact
9+
* Moderate CPU contention inside the guest; latency may spike but workload still progresses.
10+
* Early signal that the VM might need additional vCPUs or that a short‑lived process is causing bursts.
11+
12+
## Diagnosis
13+
1. **Confirm queue length**
14+
```promql
15+
kubevirt_vmi_guest_vcpu_queue{namespace="$NS",name="$VM"}
16+
```
17+
2. **Check host CPU usage**
18+
```promql
19+
rate(kubevirt_vmi_cpu_usage_seconds_total{namespace="$NS",name="$VM"}[2m])
20+
```
21+
3. **Inspect guest processes**
22+
`virtctl console <vm>``top -H` or `pidstat -u 1`
23+
4. **Verify vCPU allocation**
24+
```bash
25+
oc get vmi $VM -ojsonpath='{.spec.domain.cpu}'
26+
```
27+
28+
## Mitigation
29+
| Horizon | Action |
30+
|---------|--------|
31+
| Immediate | Optionally live‑migrate the VM to a quieter node or throttle noisy processes. |
32+
| Short term | Hot‑plug / increase vCPUs; tune application thread pools. |
33+
| Long term | Implement horizontal scaling (HPA/KEDA, VMReplicaSet); review placement rules. |
34+
35+
<!--USstart-->
36+
If you cannot resolve the issue, see the following resources:
37+
38+
- [OKD Help](https://www.okd.io/help/)
39+
- [#virtualization Slack channel](https://kubernetes.slack.com/channels/virtualization)
40+
<!--USend-->
41+
42+
<!--DS: If you cannot resolve the issue, log in to the
43+
[Customer Portal](https://access.redhat.com) and open a support case,
44+
attaching the artifacts gathered during the diagnosis procedure.-->

0 commit comments

Comments
 (0)