Mysql process not in list but constant memory eater

mohit

Well-Known Member
Jul 12, 2005
553
0
166
Sticky On Internet
hi,
i dunno what scripts are causing my box to have constant memory and cpu used by a mysql process.
show mysql processes doesn't list it.

Cpu usage in whm shows :-

datadir=/var/lib/mysql --pid-file=/var/lib/mysql/host.myserver.pid
mysql 1406 2.2 0.6 301652 13136 ? S 04:58 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/host.myserver.pid --skip-locking --port=3306 --socket=/var/lib/mysql/mysql.sock
mysql 7915 0.0 0.6 302224 13188 ? S 04:58 0:00 /usr/sbin/mysqld --basedir=/ --datadir=/var/lib/mysql --user=mysql --pid-file=/var/lib/mysql/host.myserver.pid --skip-locking --port=3306 --socket=/var/lib/mysql/mysql.sock

top command from ssh shows mysql usages but no traces of user who needs to be stopped.

please direct me to a appropriate post or suggest.

thanks & regards,
mohit
 

HostMerit

Well-Known Member
Oct 24, 2004
163
0
166
New Jersey, USA
cPanel Access Level
DataCenter Provider
Try running this at bash:

[~]# watch mysqladmin processlist

This will monitor the processlist of mysql databases / queries every 2 seconds. CTRL+C to exit.
 

HostMerit

Well-Known Member
Oct 24, 2004
163
0
166
New Jersey, USA
cPanel Access Level
DataCenter Provider
Also, try adding this to your /etc/my.cnf if you have nothing

[mysqld]
max_connections=350
max_user_connections=12


This will help by putting a limit on the max MySQL connections, and will limit the users also, so your machine will not sprial out of control.
 

mohit

Well-Known Member
Jul 12, 2005
553
0
166
Sticky On Internet
hi,
thanks for reminding me this, silly me forgot this i read this few weeks back on some post,

i see many of process with sleep time of 0-5, is it normal, p_connect is disabled in php.ini itself on this box.

One phpbb a/c. needs to be suspended as its making too many connections. may be suspending and check mem usage help me decide.

thanks for your kind attention.

regards,
mohit