My Ubuntu 10.04 server is down since this morning. When I restart it, I can use it for a couple of minutes then the RAM and Swap get full, and SSH doesn't answer. It seems ClamAV is part of the problem. How can I stop it? clamd stop didn't work.
And more globally, how can I stop all email services?
UPDATE: I don't think log files are needed anymore.
UPDATE 2:
wpc2617:~# free -m
total used free shared buffers cached
Mem: 875 868 7 0 0 12
-/+ buffers/cache: 855 20
Swap: 976 867 108
wpc2617:~# vmstat
procs -----------memory---------- ---swap-- -----io---- -system-- ----cpu----
r b swpd free buff cache si so bi bo in cs us sy id wa
1 31 971132 8076 696 18988 311 1300 2915 1309 244 200 9 2 11 77
killall clamscan
then stop whatever is starting those processes. The "D" under the S column means the processes are in "uninterruptible sleep" which could be due to various reasons but is probably due to paging to/from swap (the top also shows all your swap is used.) Killing the processes may be a challenge - see this answer - so you may need to reconfigure system not to use clamscan, then restart server.