hosted by liquidweb


Go Back   Web Hosting Talk : Web Hosting Main Forums : Hosting Security and Technology : trace mysql
Reply

Hosting Security and Technology Configuring and optimizing web hosting servers and operating systems, developing administration scripts, building servers, protecting against hackers, and general security (SSL certificates, etc.)
Forum Jump

trace mysql

Reply Post New Thread In Hosting Security and Technology Subscription
 
Send news tip View All Posts Thread Tools Search this Thread Display Modes
  #1  
Old 11-29-2006, 12:44 PM
Zion Ahead Zion Ahead is offline
Account Suspended
 
Join Date: Nov 2006
Posts: 74

trace mysql


Can someone give me several various ways to trace server load? It seems to be a mysql issue with me as I ran top -c and suspended exim to check, mysql seems to be using a lot of cpu resources

What I've done:
suspend exim
top -c
mysqladmin processlist (constantly shows eximstats), else is normal
/usr/sbin/lsof -p (which lists just about every account)
ps aux | grep mysql
lsof -p PROCESS-ID |more
Using mysql 5, centos 4 / cpanel stable version

I have about 400 accounts, mostly reseller sub accounts and about 30% disk usage.


Last edited by Zion Ahead; 11-29-2006 at 12:55 PM.
Reply With Quote


Sponsored Links
  #2  
Old 11-29-2006, 01:38 PM
david510 david510 is offline
Web Hosting Master
 
Join Date: Oct 2004
Location: Kerala, India
Posts: 4,617
If mysql is taking lot of cpu resourses, you have to find out which database is eating up the resourses. You can use mysqladmin processlist for this
May be use mysqladmin processlist -i4
This will refresh in every 4 seconds. Then you will be able to see if it is any particular database which is causing the issue.
Also, what is your my.cnf file? Have you optimized it?

__________________
David | www.cliffsupport.com
Affordable Server Management Solutions sales AT cliffsupport DOT com
iWebManager | Access WHM from iPhone and Android

Reply With Quote
  #3  
Old 11-29-2006, 01:43 PM
Zion Ahead Zion Ahead is offline
Account Suspended
 
Join Date: Nov 2006
Posts: 74
my.cnf


#DO NOT MODIFY THE FOLLOWING COMMENTED LINES!
#Created with ELS from www.servermonkeys.com
#els-build=5.0
[mysqld]
datadir=/var/lib/mysql
skip-locking
skip-innodb
#skip-networking
safe-show-database
query_cache_limit=1M
query_cache_size=128M ## 32MB for every 1GB of RAM
query_cache_type=1
max_user_connections=225
max_connections=550
interactive_timeout=10
wait_timeout=20
connect_timeout=20
thread_cache_size=128
key_buffer=512M ## 128MB for every 1GB of RAM
join_buffer=1M
max_connect_errors=20
max_allowed_packet=16M
table_cache=1024
record_buffer=1M
sort_buffer_size=4M ## 1MB for every 1GB of RAM
read_buffer_size=4M ## 1MB for every 1GB of RAM
read_rnd_buffer_size=4M ## 1MB for every 1GB of RAM
thread_concurrency=8 ## Number of CPUs x 2
myisam_sort_buffer_size=64M
server-id=1
log_slow_queries=/var/log/mysql-slow-queries.log
long_query_time=2
collation-server=latin1_general_ci

[mysql.server]
user=mysql
old-passwords = 1

[safe_mysqld]
err-log=/var/log/mysqld.log
pid-file=/var/lib/mysql/mysql.pid
open_files_limit=8192

[mysqldump]
quick
max_allowed_packet=16M

[mysql]
no-auto-rehash
#safe-updates

[isamchk]
key_buffer=64M
sort_buffer=64M
read_buffer=16M
write_buffer=16M

[myisamchk]
key_buffer=64M
sort_buffer=64M
read_buffer=16M
write_buffer=16M

[mysqlhotcopy]
interactive-timeout


Before I increased the below from 200 and 500 to what is shown now

max_user_connections=225
max_connections=550

Reply With Quote
Sponsored Links
  #4  
Old 11-29-2006, 01:46 PM
Zion Ahead Zion Ahead is offline
Account Suspended
 
Join Date: Nov 2006
Posts: 74
eximstats is constantly showing up when I run
mysqladmin processlist -i4

Reply With Quote
Reply

Related posts from TheWhir.com
Title Type Date Posted
Web Hosting Control Panel cPanel and WHM Version 11.32 Adds Features, Fixes Web Hosting News 2012-04-08 11:51:35
cPanel Launches Version 11.32 of Control Panel and Web Host Manager Web Hosting News 2012-02-15 12:46:33
Web Host Rackspace Launches Private Beta for MySQL Cloud Database Web Hosting News 2011-12-01 21:09:51
Parallels Now Offering Licenses for CloudLinux OS Web Hosting News 2011-10-26 17:29:25
Web Host FireHost Partners with Cloud Security Firm Gazzang for Data Encryption Web Hosting News 2011-08-16 20:33:43


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes
Postbit Selector

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump
Login:
Log in with your username and password
Username:
Password:



Forgot Password?
Advertisement:
Web Hosting News:



 

X

Welcome to WebHostingTalk.com

Create your username to jump into the discussion!

WebHostingTalk.com is the largest, most influentual web hosting community on the Internet. Join us by filling in the form below.


(4 digit year)

Already a member?