Subject: Find out memory usage per process in ddb
To: None <tech-kern@netbsd.org>
From: Tomas =?iso-8859-1?q?Sk=E4re?= <tomas@nocrew.org>
List: tech-kern
Date: 02/02/2004 13:35:48
Hi,
I'm running netbsd 1.6 on a PPC machine which has 64MB ram but no
swap. Sometimes, the machine panics in pagedaemon, most likely due to
lack of memory. I get to ddb, but I can't find any way there to see
how much memory each process takes? I've had a look at "show all
procs/a" and "show map/f ...", but I don't understand the output.
output from show uvmexp:
Current UVM status:
pagesize=4096 (0x1000), pagemask=0xfff, pageshift=12
13991 VM pages: 2225 active, 1116 inactive, 100 wired, 67 free
min 10% (25) anon, 10% (25) file, 5% (12) exec
max 80% (204) anon, 50% (128) file, 30% (76) exec
pages 987 anon, 1625 file, 961 exec
freemin=64, free-target=85, inactive-target=1115, wired-max=4663
faults=684992, traps=9668328, intrs=8696855, ctxswitch=18686643
softint=1721630, syscalls=7667380, swapins=0, swapouts=0
fault counts:
noram=0, noanon=0, pgwait=0, pgrele=0
ok relocks(total)=2321(2321), anget(retrys)=562917(0),
amapcopy=5439
neighbor anon/obj pg=9174/75623, gets(lock/unlock)=29806/2323
cases: anon=558288, anoncow=4629, obj=19842, prcopy=9962, przero=89832
daemon and swap counts:
woke=63, revs=63, scans=29889, obscans=11064, anscans=361
busy=0, freed=0, reactivate=13689, deactivate=31076
pageouts=0, pending=0, nswget=0
nswapdev=0, nanon=13103, nanonneeded=13103 nfreeanon=12348
swpages=0, swpginuse=0, swpgonly=0 paging=0
Something I don't understand about this output is the number of VM
pages. Total is far more than the sum of active, inactive, wired and
free. What is the rest?
Greetings,
Tomas