Mysql – Enabling both local and remote connections to a thesql server on linux (ubuntu)

connectionsMySQLremote

Is there any way to enable both remote connections and connections via "localhost" to a mysql server. I tried adding both

bind-address = 127.0.0.1

and

bind-address = externalIP

but it just used the one later in the file

Is this something that is possible or will I have to just use one?

Best Answer

You can set it to:

bind-address = 0.0.0.0

Which will allow both. "If the address is 0.0.0.0, the server accepts TCP/IP connections on all server host IPv4 interfaces. "

More info: https://dev.mysql.com/doc/refman/5.6/en/server-options.html#option_mysqld_bind-address