TestOut Linux Pro Practice Test 2025 – Complete Exam Prep Guide

Question: 1 / 400

How do you check which processes are using the most memory?

top

ps aux --sort -%mem

The command `ps aux --sort -%mem` is a powerful way to check which processes are consuming the most memory on a Linux system. In this command:

- `ps aux` provides a detailed snapshot of all running processes, displaying their user, process ID, CPU usage, memory usage, and more.

- The `--sort -%mem` option sorts the results by memory usage in descending order, allowing you to quickly identify which processes are utilizing the most RAM.

This approach gives you a precise view of resource consumption and is particularly useful for performance monitoring and troubleshooting.

While options such as `top` and `htop` are also valid tools for monitoring system resources, they present information in real-time and often with more interactive features. However, they don't inherently sort by memory usage unless you specifically configure them to do so. Meanwhile, `memusage` is not a commonly recognized command in standard Linux distributions, which makes it less appropriate for this context.

Thus, the choice to use `ps aux --sort -%mem` provides a straightforward and effective method for identifying memory-intensive processes in a clear and static output.

Get further explanation with Examzify DeepDiveBeta

memusage

htop

Next Question

Report this question

Subscribe

Get the latest from Examzify

You can unsubscribe at any time. Read our privacy policy