Jump to content

Mapping MYSQL connections to apache processes


lampstax

Recommended Posts

Hi guys,

 

I'm running into a pretty obscure problems.  Once in a while, our website would go down for a few seconds and come back up.  Server load would spike 20 or 30 times normal for a few seconds ( causing blank pages and 404s ) and settle back down.  We have already checked slow logs and optimized the queries so I'm pretty confident that its not a single bad query killing the db.   

 

We also noticed that during most of these spikes, mysql would hit max connection so my suspicion is that because of the way its coded, each hit to a certain part of our site creates multiple mysql connection, I need a way to map apache processes ( preferably with referring url ) to the number of mysql connections opened for each process and also see how long the connections are kept by the process.  Maybe the connections need to be manually closed or something like that.  SHOW FULL PROCESSLIST isnt doing enough for us.

 

Does anyone know of any monitoring program that could give us a map view of the website hit to mysql connection or more debugging data for this type of problem?

 

Thanks ahead of time.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.