All pages
Powered by GitBook
1 of 1

Loading...

SHOW PROCESSLIST

View currently executing threads. This statement displays the ID, user, host, database, statement, time, and state of active connections.

Syntax

Description

SHOW PROCESSLIST shows you which threads are running. You can also get this information from the table or the command. If you have the , you can see all threads. Otherwise, you can see only your own threads (that is, threads associated with the MariaDB account that you are using). If you do not use theFULL keyword, only the first 100 characters of each statement are shown in the Info field.

The columns shown in SHOW PROCESSLIST are:

Name
Description

The table contains a number of additional columns. See TIME_MS column in for differences in the TIME column between MariaDB and MySQL.

Note that the PROGRESS field from the information schema, and the PROGRESS field from SHOW PROCESSLIST display different results. SHOW PROCESSLIST shows the total progress, while the information schema shows the progress for the current stage only.

Threads can be killed using their thread_id or their query_id, with the statement.

Since queries on this table are locking, if the is enabled, you may want to query the table instead.

Examples

See Also

This page is licensed: GPLv2, originally from

SHOW [FULL] PROCESSLIST

STATE

See .

INFO

The statement being executed.

PROGRESS

The total progress of the process (0-100%) (see ).

ID

The client's process ID.

USER

The username associated with the process.

HOST

The host the client is connected to.

DB

The default database of the process (NULL if no default).

COMMAND

The command type. See Thread Command Values.

TIME

The amount of time, in seconds, the process has been in its current state. For a replica SQL thread before , this is the time in seconds between the last replicated event's timestamp and the replica machine's real time.

information_schema.PROCESSLIST
mariadb-admin processlist
PROCESS privilege
information_schema.PROCESSLIST
information_schema.PROCESSLIST
KILL
performance_schema
THREADS
CONNECTION_ID()
fill_help_tables.sql
SHOW PROCESSLIST;
+----+-----------------+-----------+------+---------+------+------------------------+------------------+----------+
| Id | User            | Host      | db   | Command | Time | State                  | Info             | Progress |
+----+-----------------+-----------+------+---------+------+------------------------+------------------+----------+
|  2 | event_scheduler | localhost | NULL | Daemon  | 2693 | Waiting on empty queue | NULL             |    0.000 |
|  4 | root            | localhost | NULL | Query   |    0 | Table lock             | SHOW PROCESSLIST |    0.000 |
+----+-----------------+-----------+------+---------+------+------------------------+------------------+----------+
Thread States
Progress Reporting
MariaDB 10.1