How to KILL OLD PROCESSES
If you're running out of memory, it's often because some processes started by
previous users of the workstation are inadvertently left running, taking up
CPU time and memory.
You can see if this is the case by typing the following at the athena% prompt:
ps aux
on a Linux box, or
ps -ef
if you're on a Sun, or
ps -AX
on an SGI.
This will produce output like:
USER PID %CPU %MEM SZ RSS TT STAT TIME COMMAND
17658 30.3 3.5 986 309 v0 R N 72:01 /usr/athena/emacs -i
11254 29.6 3.6 911 312 p0 R N 615:59 (emacs)
joeuser 18275 28.9 4.7 155 127 p0 R 0:00 (ps)
2056 27.8 3.6 887 312 p0 R N 2080:30 (emacs)
joeuser 18276 22.1 3.9 190 136 p0 S 0:00 (olc)
root 18055 4.5 12.0 916 329 ? S 12:48 - -v :0 ttyv0 (Xqvss)
root 18071 1.1 3.5 540 123 v0 S 0:26 xterm -geometry 80x56+0+0
joeuser 18087 0.8 1.8 330 41 v0 S 1:22 xclock -update 1 -geometry 100
joeuser 18077 0.6 2.6 247 97 p0 S 0:20 (csh)
joeuser 18272 0.4 4.2 207 145 p1 I 0:00 (olc)
root 18084 0.2 4.1 1039 135 v0 I 0:20 xterm -rw -sb -sl 2048 -title
root 211 0.1 0.8 44 15 ? I 10:16 /etc/cron
joeuser 18069 0.1 7.9 779 212 v0 I 0:52 mwm
root 207 0.1 0.4 5 3 ? I 8:23 /etc/update -n
daemon 241 0.0 0.7 393 9 ? I 14:18 /etc/snmpd
root 62 0.0 2.8 249 72 ? I 2:08 /etc/named /etc/named.boot
joeuser 18073 0.0 6.3 304 170 v0 I 0:08 /usr/etc/zwgc
root 2 0.0 0.6 1216 0 ? D 9:48 pagedaemon
....
The leftover processes are the ones with the blank username or a username that
is NOT yours, root or daemon. To get rid of
them, you'll need to first become root on the workstation. If you are using a machine in one of the regular Athena clusters and don't already know the root password, first type:
tellme root
at your athena% prompt. If you are using a private machine, you should
contact the person who maintains the machine. Once you know the root
password, type :
cd /
su
at the athena% prompt, and enter the password when prompted (you won't
see it as you type it). Once you are logged in as root, you would
type:
kill 17658 11254 2056
These are the numbers in the PID column (in the ps listing above) of the
processes without anything under USER; the actual numbers you use will
depend on what you got when you typed the ps command. Finally, you log
out as root and return to your own session by typing:
exit
Now, type the command again:
ps aux (or ps -ef or ps -Ax...)
The leftover processes should be gone, and won't be taking up memory space.
last updated: 8/28/2001
|