-
MySQL spawning threads rapidly and randomly
This just started happening all of the sudden.
We are using:
PHP 4.3.11 w/ mysql API 4.1.11
When our site is live, we get about 75-100 visitors per hour. We've been closely monitoring our processlist and notice spikes of threads from 3-5 (which is normal) to over 200!
We have not been able to pinpoint the problem, and it is being blamed on my code. My code connects to the database once per script, and it's even documented in debug output. Queries per page varies from 1-24 and this shouldn't affect the number of threads we have.
The threads would show up like this in mytop:
#### root ourdb_name # Sleep
They would appear in the hundreds and then quickly dissipate over a few seconds.
What could be creating hundreds of Sleeping threads in a matter of seconds. The spikes would happen randomly, we really have no way to track the problem. Maybe someone here would have some knowledge... Thanks!
-
What programming language is the site written in? Are you destroying your database objects that you create?
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|