Contents
What is the output of the show processlist command?
The output of the SHOW PROCESSLIST command consists of the following columns: The username associated with the thread. The host to which the client is connected The default database if one selected otherwise NULL The number of seconds that the current thread has been in its current state.
What does the show processlist do in MySQL?
The SHOW PROCESSLIST command returns all currently running threads. You then can terminate the idle threads with the KILL statement. The following shows the syntax of the SHOW PROCESSLIST command: Accounts with the PROCESS privilege can view all threads. Otherwise, they can view only threads associated with their accounts.
What happens when a thread stays in a given state?
If a thread stays in a given state for many seconds, there might be a problem that needs to be investigated. The statement the thread is executing, or NULL if it is executing no statement. The statement might be the one sent to the server, or an innermost statement if the statement executes other statements.
Which is the type of command the thread is executing?
The type of command the thread is executing on behalf of the client, or Sleep if the session is idle. For descriptions of thread commands, see Section 8.14, “Examining Server Thread (Process) Information”. The value of this column corresponds to the COM_ xxx commands of the client/server protocol and Com_ xxx status variables.
Is the show processlist a bad thing?
The only bad thing about the show [full] processlist is that you can’t filter the output result. On the other hand, issuing the SELECT * FROM INFORMATION_SCHEMA.PROCESSLIST open possibilities to remove from the output anything you don’t want to see:
How to see full query from show processlist?
When using phpMyAdmin, you should also click on the “Full texts” option (“← T →” on top left corner of a results table) to see untruncated results. Show Processlist fetches the information from another table. Here is how you can pull the data and look at ‘INFO’ column which contains the whole query :