Get memory/cpu usage by application
2
votes
1
answer
736
views
**What I need**
I want to monitor system resources (namely memory and CPU usage) by application, not just by process. Just as the Windows Task Manager groups resources by the 'calling mother process,' I would like to see it that way as well.
Nowadays, applications like Firefox and VSCode spawn many child processes, and I want to get a quick and complete overview of their usage.
The solution can be a GUI or TUI, a bash script or a big one-liner. I do not really care. For it to work, I imagine I could feed it with the pid of the mother process or the name of an executable as a means of filtering.
**Example**
**What I Tried**
* I tried

htop
, but it only shows me a tree where the calling process has its own memory listed - not the ones it called.
* I tried the gnome-system-monitor
, but its the same.
* I tried a bit with ps
and free
but have not found the correct set of arguments / pipes to make them do what I want.
It stumped me that I could not google a solution for that. Maybe there is a reason for it?
Does anybody have an idea?
Asked by Y. Shallow
(23 rep)
Oct 25, 2021, 12:07 PM
Last activity: Mar 17, 2025, 01:32 PM
Last activity: Mar 17, 2025, 01:32 PM