Connect to MySQL
For Multi-Tier Solutions without Azure Database for MariaDB, you can connect to the database from the same computer where it is installed with the mysql client tool.
$ mysql -u root -p
For Multi-Tier Solutions with Azure Database for MariaDB, use the command below instead. Replace the USERNAME and HOSTNAME placeholders with the username and hostname for the Azure Database for MariaDB instance, which is available in the Azure portal (more information).
$ mysql -u USERNAME -h HOSTNAME -p
You will be prompted to enter the root user password. This is the same password entered during the server deployment process.
WordPress users can also obtain the database hostname by executing the following command:
$ sudo cat /opt/bitnami/wordpress/wp-config.php | grep 'DB_HOST'