REMOTE MYSQL ACCESS

12 posts / 0 new
Last post
#1 Sat, 07/12/2014 - 04:58
L9Dynamics

REMOTE MYSQL ACCESS

I'm running 3 different Cloud Servers, all using virtualmin. I can't seem to get the other 2 servers to talk to the sql DB. Seems to be a permissions issue. I have done about 4 hours of testing and searching. Any suggestions?

Sat, 07/12/2014 - 05:44
Locutus

There are usually three steps involved. Port 3306 must be opened in possible firewalls, MySQL must be configured to listen on all interfaces and not only localhost (which is the default), and possibly the account you wish to use needs to be configured to allow all IPs.

Step 2 and 3 can be done in Webmin's MySQL module.

Be aware though that opening up MySQL to the Internet is a potential security risk. It's highly recommended to limit access to certain IPs, through a VPN, or similar.

Sat, 07/12/2014 - 06:22
L9Dynamics

I'm able to open up the port, but whenever I start playing with the permissions sql crashes.

Sat, 07/12/2014 - 07:01
Locutus

"Crashes"? Can you elaborate that, what exactly happens, what gets logged in syslog etc? MySQL should definitely not "crash" when you change permissions.

Sat, 07/12/2014 - 07:12
L9Dynamics

I had to do a fresh virtualmin install not having that problem anymore. I'm trying to figure out the firewall right now.

Sat, 07/12/2014 - 07:14
L9Dynamics

Failed to save MySQL server options : MySQL Daemon failed to start. Starting mysqld: [FAILED]

Sat, 07/12/2014 - 07:16
L9Dynamics

None of the Commands work to restart the MySQL Server now. So I end up doing a fresh install.

Sat, 07/12/2014 - 07:16
Locutus

Sorry, I can't follow you... What exactly are you trying to do, and what messages do you get when?

Sat, 07/12/2014 - 07:25
L9Dynamics

I have two cloud servers that runs virtualmin Server1 00.000.00.01 Server2 00.000.00.02

I want Server two to keep all the DB info for both sites. So 00.000.00.02 Needs to access the DB's on 00.000.00.02

I just did a fresh install of virtualmin on 02 now I need to get 01 access to mysql02

Sat, 07/12/2014 - 07:31
Locutus

Okay. In my first post I listed what you need to do to achieve that. What issue are you having exactly at the moment?

Sat, 07/12/2014 - 07:44
L9Dynamics

Steps 2 and 3 attempt to restart and I get that error I posted earlier.

Failed to save MySQL server options : MySQL Daemon failed to start. Starting mysqld: [FAILED]

Sat, 07/12/2014 - 10:03
Locutus

What exactly did you do for steps 2 and 3? I can't reproduce any problems with changing the listen IPs and access rights of users.

When you try to start the MySQL service manually, it should give a more precise error message.

Unfortunately I can't say much more without seeing for myself what you're doing. I could offer you a Skype/screen sharing session next week.

Topic locked