A system administrator is investigating a Linux server that unexpectedly rebooted. The last messages in `/var/log/messages` (or `journalctl`) before the reboot indicate `kernel: Out of memory: Kill process 1234 (apache2) score 999 or sacrifice child`. Which type of system performance issue is primarily indicated by this log entry?
- AMemory exhaustion, leading to the OOM killer activating.
- BCPU exhaustion due to a runaway process.
- CDisk I/O contention causing severe latency.
- DNetwork saturation, preventing kernel communication.
Show answer & explanationAnswer & explanation
Correct answer: A. Memory exhaustion, leading to the OOM killer activating.
The log message `Out of memory: Kill process ...` is a direct and unmistakable indicator that the Linux kernel's Out-Of-Memory (OOM) killer has activated. This happens when the system has completely run out of available RAM and swap space, forcing the kernel to terminate processes to free up memory. This clearly points to a memory exhaustion issue.
Why the other options are wrong
- B. CPU exhaustion would show high `%us`/`%sy` in `top` and system sluggishness, but not specifically an `Out of memory` message.
- C. Disk I/O contention would result in high I/O wait (`top wa`) and slow disk operations, not an `Out of memory` error.
- D. Network saturation would cause connectivity issues and high network-related CPU (e.g., `ksoftirqd`), but not an `Out of memory` error.
OOM Killer Activation
The Linux kernel's Out-Of-Memory (OOM) killer is a mechanism that activates when the system runs out of physical RAM and swap space. It terminates processes (often large memory consumers) to free up memory and prevent a system crash. Its activation is explicitly logged with 'Out of memory' messages.
- Kernel kills processes due to lack of memory.
- Occurs when RAM and swap are exhausted.
- Logged as 'Out of memory' in kernel messages.
Memory trick: OOM Killer means Out Of Memory, a system's sad story.