0

In the output above, what does the % (percentage sign) mean ?

mysql> show processlist;
+------+--------+----------------------+----------+---------+------+--------------+------------------------------------------------------------------------------------------------------+
| Id   | User   | Host                 | db       | Command | Time | State        | Info                                                                                                 |
+------+--------+----------------------+----------+---------+------+--------------+------------------------------------------------------------------------------------------------------+                                                    |
| 1112 | usr | %:51506              | db | Query   |    0 | Sending data | CALL `db`.`GetAllHistory`('.............', '...................') |
| 1127 | usr | %:56805              | db | Query   |    1 | Sending data | SELECT ........

Other than being a wildcard in some contexts, I could not find it in the online documentation or other places.

kellogs
  • 69
  • 8

1 Answers1

1

In your listed output, under the Host column the % sign is a wildcard that means any host can connect to the database. localhost and 127.0.0.1 are typical hosts when the user is on the same host as the MySQL instance. The wildcard allows anyone with the credentials for 'usr' to connect to the 'db' (or any other databases that the user has access to) from any IP address, i.e., anywhere in the world. This is insecure, but maybe you deal with security elsewhere, e.g., firewall.