LFCS Operation of Running Systems Practice Question
Which TWO commands can be used to display real-time process resource usage on a Linux system? (Choose two.)
⚠ Common exam trap
Many candidates confuse static commands like ps and free with real-time monitoring tools, mistakenly thinking that any command showing resource data qualifies as real-time, when only those with continuous updates (like top and htop) meet the requirement.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
htop
Option B (htop) is correct because htop is an interactive process viewer that continuously refreshes and displays real-time CPU, memory, and per-process resource usage, updating by default every second. Option E (top) is correct because top is the classic interactive monitor that dynamically refreshes process and resource statistics in real time, also defaulting to a periodic update interval. Option A (vmstat 1) reports virtual memory, CPU, and I/O statistics every 1 second, but it summarizes system-wide counters rather than per-process resource usage, so it does not display process-level real-time usage. Option C (ps -aux) is a snapshot command that lists processes at the moment of execution and then exits, providing no continuous real-time updates. Option D (free -h) only shows current memory and swap utilization in human-readable units and does not display process resource usage at all.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
vmstat 1
Why it's wrong here
vmstat 1 samples system-wide CPU, memory, and I/O counters every second, but it aggregates across all processes rather than showing per-process resource usage. It is tempting because the interval argument gives real-time refresh, making it correct for system-level performance trending, not per-process monitoring.
- ✓
htop
Why this is correct
htop provides an interactive, colour-coded real-time view of per-process CPU, memory and swap consumption, refreshing continuously. It satisfies the stem's requirement to display live process resource usage, unlike static tools such as ps, which capture only a single snapshot.
- ✗
ps -aux
Why it's wrong here
ps -aux produces a static snapshot of current processes; it exits immediately and does not refresh, so it cannot show real-time usage. It is tempting because it lists per-process CPU and memory figures, making it the correct choice when a one-off process listing is needed rather than continuous monitoring.
- ✗
free -h
Why it's wrong here
free -h reports aggregate memory and swap statistics in human-readable units, not per-process resource consumption, and it does not refresh continuously. It would be the right tool for checking overall RAM usage at a single moment, but the question asks for real-time per-process monitoring.
- ✓
top
Why this is correct
top refreshes continuously, showing live per-process CPU, memory and load statistics, so it meets the stem's real-time resource-usage requirement. Unlike ps, which prints a one-off snapshot, top updates its display on a configurable interval until quit.
Go deeper
Related to this question
About these practice questions
Courseiva writes every LFCS question from scratch — 406 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This LFCS practice question is part of Courseiva's free Linux Foundation certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the LFCS exam.