010-160 · Question #5
What information can be displayed by top?
The correct answer is B. Running processes, ordered by CPU or RAM consumption. The top command is a real-time process viewer that displays running processes sorted by resource usage such as CPU or memory.
Question
Options
- AExisting files, ordered by their size.
- BRunning processes, ordered by CPU or RAM consumption.
- CUser accounts, ordered by the number of logins.
- DUser groups, ordered by the number of members.
- EUser accounts, ordered by the number of files.
How the community answered
(27 responses)- B93% (25)
- C4% (1)
- D4% (1)
Why each option
The `top` command is a real-time process viewer that displays running processes sorted by resource usage such as CPU or memory.
Listing files by size is done with commands like `ls -lS` or `du`, not `top`, which is strictly a process monitor.
The `top` utility displays a live, updating list of running processes along with their CPU percentage, memory consumption, PID, user, and other metrics. By default it sorts by CPU usage, but pressing 'M' will re-sort by memory (RAM) consumption, making it the primary tool for identifying resource-hungry processes.
User account login history is queried with commands such as `last` or `lastlog`, not `top`.
Group membership information is found in `/etc/group` or via `getent group`, not `top`.
Counting files owned by user accounts requires tools like `find` combined with `du` or custom scripts, not `top`.
Concept tested: Real-time process monitoring with top
Source: https://man7.org/linux/man-pages/man1/top.1.html
Topics
Community Discussion
No community discussion yet for this question.