Manual:Mysql.php

Details
mysql.php maintenance script executes the MySQL client binary with connecting to the wiki's DB. It directly takes credential from LocalSettings.php and getting you into MySQL client binary.

Getting into MySQL client with cluster
If you uses database cluster to run your wiki with $wgExternalServers. You can checkout to cluster.

Common error
This comes when wrong or non-exists cluster name is given to the script.
 * Error: invalid cluster

This comes when you run script on wiki that uses sqlite.
 * Error: this script only works with MySQL/MariaDB