size of text/data space of running process

Warren Burstein warren at picuxa.UUCP
Thu Aug 7 06:58:52 AEST 1986


How can one determine the amount of space taken up by a process,
broken up into text and data?  What is really wanted is
the total amount of core that will be taken up by many copies
of a shared-text process.  If you just add up the SZ's from "ps"
you count the text n times.

I read the SYS V source to ps, it seems it used to get this info
from the u structure on the pdp11 but no more, alas.

One suggestion is to get the text size from the "size" command
and assume that the rest of SZ is data (accounting for page size).
Does this work?

thanks in advance
warren
-- 

_  __  __
 |/  \/  \
 |___|___|/
 |
 |
 |
/



More information about the Comp.unix.wizards mailing list