Almost 100% memory usage

Hi All,

why is “mail” command is using 100% CPU, and memory is almost 100% used. Only Asterisk wit SIP is configured on server. Please guide how to resolve the issue

Tasks: 236 total, 3 running, 233 sleeping, 0 stopped, 0 zombie
%Cpu(s): 7.0 us, 18.3 sy, 0.0 ni, 74.6 id, 0.0 wa, 0.0 hi, 0.0 si, 0.0 st
KiB Mem: 8170728 total, 7991816 used, 178912 free, 154256 buffers
KiB Swap: 8380412 total, 222512 used, 8157900 free. 6863576 cached Mem

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
25248 root 20 0 126804 6944 5676 R 100.0 0.1 42650:45 mail
25436 root 20 0 126804 6912 5748 R 100.0 0.1 42647:13 mail

using netstat i found

tcp 0 0 xxx-xxx-xxx-xxx.co:43198 sg2pismtp01-v01.pr:smtp TIME_WAIT
tcp 0 0 xxx-xxx-xxx-xxx.co:43196 sg2pismtp01-v01.pr:smtp TIME_WAIT

and the port number is continuously increasing…
any solution?

Sounds like sendmail was installed by default in the OS.

/etc/init.d/sendmail stop

If that works, uninstall sendmail (or postfix).

yup it was installed, i killed the task. Also memory was cached so I had to clear the cache.