Man Page for mem.mon
How to use mem.mon
The link above is where you get current copies.
Program Objective: To identify processes with memory use that increases but does not decrease.
USAGE: $PRGN [ -d delay -r runs -n number -f filter -l logfile ]
-d delay The default time in seconds between information collection. The default is 3600 seconds or 30 minutes.
-r runs How many times you want it to run. The default is 12 times.
-n number The number of processes you wish to track. By default it tracks the top 20 memory users. You may need to track more processes.
-f filter This lets you filter the output for certain processes. The filter you use becomes part of the name of the log file in which the data is collected. You still need to set the program to look at enough processes to include the process you wish to filter for.
-l logfile This option lets you send the output to a logfile of your choosing. By default the name includes the date the program was launched.
mem.mon –d 7200 –r 10 –n 10
This runs the program once an your for 10 hours and tracks the top 10 memory users on the system.
mem.mon –d 1800 –r 12 –n 30 –f javaman
This looks at the top 30 memory users for a program called javaman. javaman will be part of the name. This will collect data every 15 minutes for 3 hours.
mem.mon –d 7200 –r 10 –n 30 –f myprog –l /tmp/mylog
This looks at the top 30 processes once an hour for 10 hours and puts the output into a file called /tmp/mylog. The output is filtered to only look at the process called myprog
OS supported: HP-UX all versions. Linux all versions (Tested on Red Hat and CentOS). SunOS (In test, unknown version support at this time.
/usr/contrib/bin/mem.mon -d 10 -r 10 -n 10
# run the program with a delay of 10 seconds for 10 iterations looking at the top 10 processes.
This is the output file.
-rw-r--r-- 1 root root 10714 Sep 17 15:59 memuse.mon.-17-Sep-2007.log
Mon Sep 17 15:58:00 IST 2007
PROC# -Vmem- Resident Memory --------- command ---------
PID RSS VSZ COMMAND
8013 874996 2497840 /usr/libexec/evolution/2.8/evolution-exchange-storage --oaf-activate-iid=OAFIID:GNOME_Evolution_Exchange_Connector_CalFactory:1.2 --oaf-ior-fd=40
6552 90928 241608 /usr/lib/firefox-126.96.36.199/firefox-bin http://docs.hp.com/en/J4269-90074/ch01.html
3303 63964 145032 /usr/bin/Xorg :0 -br -audit 0 -auth /var/gdm/:0.Xauth -nolisten tcp vt7
8030 39956 294560 evolution --component=mail
9102 21336 38068 spamd child
14477 17448 330896 /usr/lib/openoffice.org2.0/program/swriter.bin -writer
14122 12244 95888 /usr/bin/evince /tmp/J4269-90062.pdf
6686 9968 71800 gnome-terminal
8075 8476 32128 /usr/bin/perl -T -w /usr/bin/spamd --socketpath /root/.evolution/cache/tmp/spamd-socket-path-BV4cWc --local --max-children=1 --pidfile /root/.evolution/cache/tmp/spamd-pid-file-EcfEeT
The top memory process on this system system the evolution-exchange-storage program. It is memory resident with 874,996 KB of RAM and has Virtual memory of 2,497,840 KB
This man page was created with a short run time, but you can see that this program has a massive amount of memory reserved for a system with only 1.5 GB of RAM installed. We have on our hands a memory leaker. In this case, we can’t fix it, we need to merely report it to bugzilla.redhat.com
This program is open source, licensed for use under the GNU license agreement. You may use it without warranty at your own risk. You may distribute it so long as you leave the original author's copyright notice in the code.
This program was developed for NDS Technologies Israel and NDS and its customers have rights for support of this program under their existing agreements with NDS Technologies.
Author: Shmuel Protter NDS Technologies Israel
Technical Assistance: Victor Fridyev NDS Technologies Israel