Hey guys i'm new to this. I have a PC running win 10 and installed mysql. I have a VPS and it runs UBUNTU 14.04.5 LTS. i have registered in www.noip.com for dynamic dns. i simply wanna access my local database from VPS like
mysql -u door -h mylocaldatabase.hopto.org -P3306 -p
but i get this error:
ERROR 2003 (HY000): Can't connect to MySQL server on 'mylocaldatabase.hopto.org' (101)
what should i do?
Related
MySQL Workbench and MySQL server 8 is installed in Windows. In my WSL2 prompt, I installed the MySQL 8 client. I want to connect to the MySQL server from WSL2.
When I try mysql -u root -p -h 127.0.0.1 I get
ERROR 2003 (HY000): Can't connect to MySQL server on '127.0.0.1' (111)
On WSL I have "mysql Ver 8.0.21-0ubuntu0.20.04.3 for Linux on x86_64 ((Ubuntu))" installed. If I just try mysql localhost I get
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2)
I believe this is because I don't have the MySQL server installed on WSL just in Windows. I had this working a few days ago but then I had a Windows auto-update and I could no longer connect.
Use windows local ip address instead of 127.0.0.1
I have a remote SQL database (RDS) on Amazon Web Services which I am attempting to connect to via the Linux terminal.
Having run the following command, substituting each value:
sudo mysql -u <username> -h <endpoiont> -P <port> -p
and then entered my password, I get the following error message:
ERROR 2003 (HY000): Can't connect to MySQL server on '<endpoint>' (111)
This used to work up to a few weeks ago and I have not changed any of the AWS permissions and security settings since. I also changed the password since this error but this did not solve the problem.
My application itself can connect to the DB, only I cannot connect via the Linux terminal.
Some solutions that I have read related to making changes to local files but this SQL database is hosted on AWS, not on my local machine.
Any suggested solutions are welcome.
I've just set up my very first Debian 7.9 server. I also installed a regular LAMP stack with MariaDB. The database is working, I've already created another user.
The problem comes up when i try to connect to my server's MariaDB from my laptop (ubuntu 14.04). I installed mariadb-client on my laptop and tried to connect via:
mysql -u myusername -p myserversadress
The error I get is:
ERROR 2003 (HY000): Can't connect to MySQL server on ... (111)
What does it mean?
mysql -u myusername -p -h myserversadress
The "host" was assumed to be localhost, and they command, if it could connect, would look for database myserversadress.
I've installed the mysql community server, server is running, and i'm able to connect through command line using
mysql -u root -p -h 127.0.0.1 -P 3307
which is the community server. I've also installed wamp which has its mysql server running on port 3306, the command above also connects to that server again
wamp is running fine and i'm able to get into phpmyadmin just fine, but when i try connecting to either mysql server through localhost using workbench, i'm presented with an error "Failed to connect to MySQL at 127.0.0.1:3307 with user root
Unknown MySQL server host '127.0.0.1' (0)"
I've been searching online for hours now and i can't seem to find any solutions to this. The only problem i'm having is connecting through workbench.
Are there any settings for workbench that i might have to change in order to connect to the servers?
EDIT:
This is all on windows by the way. I've also reinstalled wamp, workbench, and mysql server multiple times
I'm trying to connect to the mysql server on my mac using terminal. I've already got MAMP on my mac but now I have installed XAMPP. when I type this into my terminal
mysql -u root -p
it comes up with this message...
ERROR 2002 (HY000): Can't connect to local MySQL server through socket
'/Applications/MAMP/tmp/mysql/mysql.sock' (2)
I'm wondering is it because of XAMPP? Any suggestions?
have you tried
mysql -h 127.0.0.1 -u root -p
(if the mysql server isn't running on your local box, substitute the IP address of the mysql server for 127.0.0.1)