ERROR 2003 (HY000): Can't connect to MySQL server on 'hostname/ipaddress'

Wael ElSawy

Registered
Mar 2, 2014
1
0
1
cPanel Access Level
Website Owner
Hi guys,

I know my question is so silly and old but i don't know to connect my pc remotely to the database i created in cpanel, although i added % in the host field of Remote MySQL.

i get error message when i try to connect it via command line:

shell> mysql -u cpanelusername -p -h domain
Enter password: cpanelpassword
ERROR 2003 (HY000): Can't connect to MySQL server on 'hostname/ipaddress' (10060)

Any one can help me please?
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello :)

Make sure you add the IP address you are connecting from to the "Remote MySQL" option in cPanel for this account. Try using your actual IP address instead of a wildcard. Also, make sure no firewall rules on your server or home computer are restricting the connection attempt.

Thank you.