Tell me more ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

as you can see from the screen print below mysql is using a lot of cpu, when there isnt much going on. i have had to restore to a default my.conf so i might need some settings changing. could be wrong and what would you recommend.

This is the log for mysql under WHM CPU 779 %

Memory 3.9%

/usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib/mysql/plugin --user=mysql --log-error=/var/lib/mysql/server.sy2.com.err --pid-file=/var/lib/mysql/server.sy2.com.pid

Linux server.sy2.com 2.6.18-308.8.1.el5PAE #1 SMP Tue May 29 15:37:08 EDT 2012 i686 i686 i386 GNU/Linux

Server version: 5.5.24-cll MySQL Community Server (GPL)

[mysqld]
# safe-show-database
wait_timeout=180
max_allowed_packet=32M
max_user_connections=200
innodb_buffer_pool_size=512M
collation-server=latin1_general_ci
server-id=1
max_connect_errors=100
table_cache=1024
connect_timeout=20
innodb_log_buffer_size=8M
#datadir="/var/lib/mysql"
thread_cache_size=64
read_buffer_size=1M
skip-external-locking
innodb_file_per_table=1
sort_buffer_size=2M
thread_concurrency=16
query_cache_type=1
local-infile=0
query_cache_limit=1M
max_connections=1000
myisam_sort_buffer_size=64M
skip-name-resolve
read_rnd_buffer_size=4M
innodb_thread_concurrency=8
join_buffer=1M
socket="/var/lib/mysql/mysql.sock"
skip-host-cache
key_buffer=1024M
innodb_additional_mem_pool_size=64M
query_cache_size=128M
innodb_flush_log_at_trx_commit=0
old-passwords = 1

[isamchk]
read_buffer=16M
sort_buffer=64M
key_buffer=64M
write_buffer=16M
[mysqlhotcopy]
interactive-timeout

MemTotal:     16624132 kB
MemFree:      11571124 kB
Buffers:        349460 kB
Cached:        3228736 kB
SwapCached:         12 kB
Active:        2760036 kB
Inactive:      1839548 kB
HighTotal:    15849956 kB
HighFree:     11562188 kB
LowTotal:       774176 kB
LowFree:          8936 kB
SwapTotal:    35841004 kB
SwapFree:     35840992 kB
Dirty:          169072 kB
Writeback:           0 kB
AnonPages:     1020796 kB
Mapped:          31764 kB
Slab:           403784 kB
PageTables:      10376 kB
NFS_Unstable:        0 kB
Bounce:              0 kB
CommitLimit:  44153068 kB
Committed_AS:  3735304 kB
VmallocTotal:   116728 kB
VmallocUsed:     22864 kB
VmallocChunk:    92444 kB
HugePages_Total:     0
HugePages_Free:      0
HugePages_Rsvd:      0
Hugepagesize:     2048 kB


model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
model name      : Intel(R) Xeon(R) CPU           E5620  @ 2.40GHz
share|improve this question
what about your queries? do you have slow query log file? – vahid chakoshy Sep 1 '12 at 4:06
1  
SHOW PROCESSLIST as the root user would show you what's going on internally. The MySQL Administrator tool can run this for you in real-time to give you an idea what's running wild. – tadman Sep 1 '12 at 4:54
@tadman i just ran the command and this is whats it showing up with but the load on the process is 51% at the moment. SHOW PROCESSLIST; +-------+------+-----------+------+---------+------+-------+------------------+ | Id | User | Host | db | Command | Time | State | Info | +-------+------+-----------+------+---------+------+-------+------------------+ | 34533 | root | localhost | NULL | Query | 0 | NULL | SHOW PROCESSLIST | 1 row in set (0.00 sec) vahid i do and there isnt much slowing down the database – user1023145 Sep 1 '12 at 9:37
Have you tried turning it off and on again? – tadman Sep 1 '12 at 22:04
Yes i tried that and also moved to a new server. the problem was apache even though it was showing high load for mysql the performance problem as due to apache. so i changed it to prefork and the load dropped from 250 to 0.5. – user1023145 Sep 2 '12 at 20:36

migrated from stackoverflow.com Oct 1 '12 at 2:28

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.