Can't connect to remote MySQL server with error 61

can band
can definition
can you
can bus
can synonym
can noun meaning
can (tago mago)
can ege bamyasi

When I tried to connect the remote MySQL server by using command line mysql -h <remote-ip> -u any_existing_users -p or any other mysql client such as phpmyadmin, it didn't work and the error hint was

ERROR 2003 (HY000) Can't connect to MySQL server on '<remote-ip>' (61)

But, when I tried ssh <remote-ip> and connected the MySQL locally by mysql -u root -p, there is no problem.

Here is part of the user table(SELECT User, Host FROM mysql.user;):

+------------------+----------------+
| User             | Host           |
+------------------+----------------+
| root             | %              |
| other_users      | <remote-ip>    |
| root             | localhost      |
+------------------+----------------+

Here is the iptable:

Chain INPUT (policy ACCEPT)
num  target     prot opt source               destination         
1    RH-Firewall-1-INPUT  all  --  0.0.0.0/0            0.0.0.0/0           

Chain FORWARD (policy ACCEPT)
num  target     prot opt source               destination         
1    RH-Firewall-1-INPUT  all  --  0.0.0.0/0            0.0.0.0/0           

Chain OUTPUT (policy ACCEPT)
num  target     prot opt source               destination         

Chain RH-Firewall-1-INPUT (2 references)
num  target     prot opt source               destination         
1    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           
2    ACCEPT     icmp --  0.0.0.0/0            0.0.0.0/0           icmp type 255 
3    ACCEPT     esp  --  0.0.0.0/0            0.0.0.0/0           
4    ACCEPT     ah   --  0.0.0.0/0            0.0.0.0/0           
5    ACCEPT     udp  --  0.0.0.0/0            224.0.0.251         udp dpt:5353 
6    ACCEPT     udp  --  0.0.0.0/0            0.0.0.0/0           udp dpt:631 
7    ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           tcp dpt:631 
8    ACCEPT     all  --  0.0.0.0/0            0.0.0.0/0           state RELATED,ESTABLISHED 
9    ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           state NEW tcp dpt:22 
10   REJECT     all  --  0.0.0.0/0            0.0.0.0/0           reject-with icmp-host-prohibited 
11   ACCEPT     tcp  --  0.0.0.0/0            0.0.0.0/0           state NEW tcp dpt:3306 

So, what's the problem?

Check if your mysql server is listening on a socket with netstat:

netstat -tulpen

and search for 3306.

If not or if only on localhost, check my.cnf and search the bind-address line and change it to:

bind-address = 0.0.0.0

then restart the server and try again.

Can (band), Can definition is - be physically or mentally able to. How to use can in a sentence . can vs. may. can - WordReference English dictionary, questions, discussion and forums. All Free.

Check status:

netstat -tulpen

Modify your configuration:

nano /etc/mysql/my.cnf
# Edit:
bind-address = 0.0.0.0

Enter mysql and give privileges:

mysql -umyuser -pmypassword
# Run:
GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'%'IDENTIFIED BY 'mypassword' WITH GRANT OPTION;
FLUSH PRIVILEGES;
exit

Restart mysql

/etc/init.d/mysql restart

Can, Nas' official music video for 'I Can'. Click to listen to Nas on Spotify: http://smarturl Duration: 4:27 Posted: 22 Mar 2011 Rutgers Canvas is pleased to announce the integration of Flipgraid, a free video discussion platform from Microsoft that helps educators see and hear from every student in class and foster a fun and supportive social learning environment.

With MySql 5.7 they changed files so bind-address are now in:

/etc/mysql/mysql.conf.d/mysqld.cnf

instead of:

/etc/mysql/my.cnf

CAN, VerbEdit. can (third-person singular simple present can, present participle -, simple past could, past participle (obsolete except in adjectival use) couth). We would like to show you a description here but the site won’t allow us.

If you run MAMP, do not forget to allow access (mySQL panel, check "Allow network access to MySQL")

Can, 1.4Used to indicate that something is typically the case. 'antique clocks can seem out of place in modern homes'. More example sentences. Forgot Password? Enter your Email and we'll send you a link to change your password.

I had this problem just after installing Centos 7 on a server. I could´t access to it through Mysql Workbench in a remote computer.

The problem was in the firewall configuration. Eventually, the solution came when doing:

sudo firewall-cmd --zone=public --permanent --add-service=mysql

And then, restart the firewall:

sudo systemctl restart firewalld

Nas - I Can (Official Video), Your household - as defined in law - is only the people you live with. If you are a single adult household and have formed a support bubble these can be treated as� The Climate Action Network (CAN) is a worldwide network of over 1300 Non-Governmental Organizations (NGOs) in over 130 countries working to promote government and individual action to limit human-induced climate change to ecologically sustainable levels.

can, Can Trump ban TikTok? What the executive order means – explained. The move requires TikTok and WeChat to find new owners or shut down,� Can-Am offers a complete lineup of Off-Road vehicles (ATV, Side-by-Side) and 3-wheel motorcycles (Spyder or Ryker). Choose your playground now and enjoy the Can-Am World!

Can, Access Canvas, get training, find support, look-up grades, and download apps. Students and faculty use canvas to complete and administer course materials.

FAQ on local restrictions, We would like to show you a description here but the site won’t allow us.

Comments
  • Please check my post here. It might help you: stackoverflow.com/a/22637763/676508
  • A line shows tcp 0 0 :::3306 :::* LISTEN 100 1. What does ::: mean here? Does that mean mysql binds on an IPv6 address?
  • Seems like it, but I don't know cent os to be sure. Did you try to connect via ip on localhost? Connect via ssh and do "mysql -u user -p -h 127.0.0.1" or the public ip address of your server and test if you can connect. A simple "mysql -u user -p" could also connect through a socket file.
  • mysql -u user -p -h 127.0.0.1, mysql -u user -p -h 0.0.0.0 and mysql -u user -p -h <remote-ip> all work fine.@Kaffee
  • yeah ok so mysql server seems to be fine. now its either a firewall on your host, client or in the network.
  • Yes, it is. The network supports ipv6 yesterday, and the iptable just accepts request via ipv4 address. And the problem is solved. Thank you.
  • While accurate, I would be more careful when granting privileges without a warning
  • this worked for me. but I just had to use sudo for step 2 and step 4
  • What can I do, when I don't have data in my.cnf file ? stackoverflow.com/questions/56517064/…
  • same as above ^
  • @andyp why do you think so? It looks like a (very short, but still) anwer to me.
  • @Jan: you're correct, I was too quick to dismiss this as a comment earlier