Connect to MySQL/MariaDB from a different machine

Before running the commands shown on this page, you should load the Bitnami stack environment by executing the installdir/use_APPNAME script (Linux and Mac OS X) or by clicking the shortcut in the Start Menu under “Start -> Bitnami APPNAME Stack -> Application console” (Windows). Learn more.

IMPORTANT: Bitnami Native Installers do not modify the firewall configuration of your computer, therefore the CiviCRM ports could be open which is a significant security risk. You are strongly advised to close the CiviCRM ports (refer to the FAQ for more information on this).

To connect to your database server remotely using the MySQL client, follow these steps:

Windows, Mac OS X, Linux

Open port 3306 in your firewall. For example, if you are using ufw, you would run the following commands (on Linux only):

$ sudo ufw allow mysql/tcp

At the server console, edit the file installdir/mysql/my.cnf and find the line containing

bind-address=127.0.0.1

Comment out this line by placing a hash (#) symbol at the beginning, so that it looks like this:

#bind-address=127.0.0.1

Save the file.

At the server console, allow remote access to the database server using the command line client. Use the following command, remembering to replace PASSWORD with the application password from the first step: