iandow Tux's lil' helper
Joined: 21 Jul 2004 Posts: 135 Location: Washington, DC
|
Posted: Thu Feb 02, 2006 3:46 pm Post subject: measuring memory usage with time(1) |
|
|
The unix time utility includes an option for measuring the amount of memory a process consumes while running (see time(1) man page, options %M, %t, %K, %D). But, whenever I run time with any of those options, they always end up giving me _zero_.
The time(1) man page's BUG section states that "Not all resources are measured by all versions of Unix, so some of the values might be reported as zero."
Does anyone know how to fix this bug for gentoo?
Here's a good test:
Code: | /usr/bin/time -f '%S %M %t %K ' gimp |
To which I get the following output:
Or, does anyone know of another utility I can use to get a measurement of a process's memory usage? The problem with ps and top is that they don't *add* up the total memory usage, they just show current usage.
Thanks.
-ian |
|