I have a server with Rackspace. I want to access the database from my local machine command line.
I tried like:
mysql -u username -h my.application.com -ppassword
But it gives an error:
ERROR 2003 (HY000):
Can't connect to MySQL server on 'my.application.com' (10061)
What causes this error and how can I connect to the remote database?
I was too getting the same error. But found it useful by creating new mysql user on remote mysql server ans then connect. Run following command on remote server:
Now you can connect with remote mysql with following command.
Here is the full post:
http://openvani.com/blog/connect-remotely-mysql-server/
For Mac, use the following command:
and then enter the password when prompted.
Try this command
mysql -uuser -hhostname -PPORT -ppassword
.I faced a similar situation and later when mysql port for host was entered with the command, it was solved.
simply put this on terminal at ubuntu:
Now hit enter
terminal will ask you password, enter the password and you are into database server
I assume you have MySQL installed on your machine. Execute the command below after filling missing details:
You should put your password with 'p'