简体   繁体   中英

MySql - Where are the pending processes?

I am launching hundreds of php scripts simultaneously. To have an overview of the 'activty', I am doing a SHOW PROCESSLIST in mySql. This returns 5 processes including the SHOW PROCESSLIST one. So I am wondering where all the other pending processes are before being processed. Is there a command to see those? Thank you for your replies. Cheers. Marc

Try this:

SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST

If you not see what you are expecting, then PHP script is not making query in the time this select runs.

More info about server threads you can find here

You can also use mysqlproxy to see everything.

See the manual, and in particular:

http://dev.mysql.com/doc/refman/5.6/en/show-processlist.html

If you have the PROCESS privilege, you can see all threads. Otherwise, you can see only your own threads (that is, threads associated with the MySQL account that you are using)

Maybe the php script and the client doing SHOW PROCESSLIST are using a different account ...

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM