-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathREADME
More file actions
23 lines (16 loc) · 944 Bytes
/
README
File metadata and controls
23 lines (16 loc) · 944 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
rmemusage tries to show the real memory usage used by processes/users on linux. It uses libproc to query process information and estimate _real_ per-process memory usage.
To build:
g++ main.cc -l procps -o rmemusage
Note: It appears that on some system you need to replace procps by proc in the previous command
To run (as root to have information about all processes):
# ./rmemusage [-u]
When ran without options, it simply output all processes currently running and their memory usage. When ran with the -u option, it calculate memory usage per-user.
Columns description:
PID: Process id (posix thread id)
PPID: Parent process
NAME: Process name
USER: User running that process
RSS: Resident Set Size, it's the process memory usage + memory used by all shared libs it uses
PSS: Proportional Set Size (process memory + fraction of shared memory with other processes)
SWAP: Part of the process memory that is swapped
REAL: PSS + SWAP