LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 12-09-2012, 09:13 PM   #1
ubungu
LQ Newbie
 
Registered: Jun 2012
Location: /home/ubungu
Posts: 27

Rep: Reputation: Disabled
How MySQL process sleep connection?


Hi everybody!

My PHP Application isn't using persistent connection

Some MySQL Server variables
wait_timeout: 300
interactive_timeout: 300
max_connections: 100

Assume show processlist have 50 Sleeps thread and all TIME < 300

If there are 4 new connect from my PHP Application.
2 connection mysql_connect(user,host,pass,false); CASE 1
2 connections mysql_connect(user,host,pass,false); CASE 2

How MySQL process those connections

I think CASE 1, MySQL Server will select connection in sleep connections and then assign that connection for client request
CASE 2, MySQL Server will create new thread and assign that connection for client request

Consider CASE 1. If I think correct, how MySQL select sleep connection in many sleep connect. And if I don't think corrent, how MySQL process CASE 1

Sorry for my bad English skill :d Thank you very much
 
  


Reply



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



Similar Threads
Thread Thread Starter Forum Replies Last Post
MySQL process - Sleep. What does it mean? linuxfond Linux - Newbie 7 04-11-2009 08:04 PM
How to make a process sleep? bjdea1 Linux - General 1 12-11-2007 09:58 AM
MATLAB process wants to SLEEP! amwink Linux - Kernel 2 02-05-2007 08:26 PM
process in Disk sleep rahulk Linux - Software 5 06-29-2006 06:06 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 04:48 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration