memory usage ενός script/commad?

V13 v13 at priest.com
Wed Oct 4 00:47:16 EEST 2006


On Monday 02 October 2006 16:07, Argiris Mokios wrote:
> Καλησπέρα,
>
> προσπαθώ να μετρήσω μερικά στατιστικά στοιχεία για κάποια
> scripts/commads που
> εκτελώ με την time, αλλά δεν μου δίνει στοιχεία σχετικά με την χρήση
> μνήμης.
>
> /usr/bin/time -f"\t Average total memory use: %Kkbytes\n" script
>
> Average total memory usage: 0kbytes
>
> Έχει κανείς να προτείνει κάποια εναλλακτική μέθοδο;

  Mia plagia lysh einai na deis ta page faults, na ta athroiseis kai na ta 
polaplasiases me to 4 (page size) gia na pareis ta Kbyte. 

  To na metriseis th mnhmh poy xreiazetai ena programma einai ligo mystirio. 
Pos akribos to enoeis? 
 * Metras kai th mnhmh poy exei desmeysei alla den exei xrhsimopoihsei?
 * Metras kai th vm poy katanalonetai logo mmap()? [1]
 * Se ena programma poy doylepse gia 1 mera, metras kai th mnhmh poy 
xreiastike mia fora kai meta egine gia panta swap-out?

  Genika, tha eixe shmasia an mporoyses na metrhseis to average kai max RSS 
gia na ksereis to posi pragmatika mnimi xreiazetai to programma, alla ayto 
einai statistiko stoixeia kai dystixos den to metraei.

  (Flame bait) Sto IRIX p.x, to process accounting metraei kai to meso RSS:

COMMAND                   START    END             REAL        CPU      MEAN
NAME       USER  TTYNAME  TIME     TIME          (SECS)     (SECS)   SIZE(K)
#sendmail  root  ?        00:41:17 00:41:17        0.54       0.01   3248.00
acctcom    v13   pts/1    00:41:15 00:41:17        2.51       0.04     68.00

<<V13>>

[1] An h apanthsh soy einai nai, tote ta apotelesmata tha'nai entelos lathos. 
An einai oxi, tote exe sto noy oti to memory allocation apo th glibc 2.3 kai 
meta ginetai me mmap sto /dev/null.




More information about the Linux-greek-users mailing list