Mem usage of a process with getrusage

Christian Loth (
Mon, 6 Jul 1998 20:38:58 +0200 (MESZ)


Some unix faq pointed me to the function getrusage() for finding out
about a processes memory usage. Now I did, and startling I found out that
the fields of the rusage struct which were of interest to me returned 0.
I had a look at the implementation in kernel/sys.c of getrusage() and saw,
that those fields (ru_maxrss and following friends) were not used (at least
not in the kernel version 2.0.33). Now, is there any other way to find out
about a processes memory from within the process?

- Chris

| Christian Loth                      | Meet me as the >Shadowdancer< in the | 
|                    |           REALM OF MAGIC             |
|            | telnet 4000               |
|                                     |                   |
|               "The road goes ever on and on!" - Bilbo Baggins              |

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to