1

I have a sandbox server, I want to access Server MySQL remotely on my ubuntu setup without opening Putty or any other medium ie in my local Command prompt.

I tried this way -

enter image description here

Here I made a new user test with '%' , so that it is accessible from all IPs. Then I granted all the permissions and flushed privileges.

But couldn't access Server MySQL locally - enter image description here

here I tried all the versions of command which I found during my searches for the process.

What I should do and how, please help. And how can changes should I make further to access Server MySQL remotely.

Shadow
  • 33,525
  • 10
  • 51
  • 64
Gaurav Gupta
  • 405
  • 7
  • 23

1 Answers1

1

Remote access is disabled by default in MySQL servers. You need to edit my.cnf file and add a line

bind-address=YOUR-SERVER-IP

and disable skip-networking - so that the server does not listen for TCP/IP connections at all. All interaction with mysqld must be made via Unix sockets.

Remember to restart mysqld after you save the cnf file.

Then you will need to open TCP port 3306 of the server using iptables.

smartdroid
  • 312
  • 2
  • 10