After installing MySql server on a Linux machine (Debian 5) I got this error message when trying to connect to the Mysql server using Mysql administrator.
When trying to fix the problem and searching the Internet I found out that the problem is easy then what it looked.
By default Mysql server only allows the local host to access the Mysql server.
To fix the problem all we need to edit the mysql config file and add the mysql external ip address to accept connection from (not the localhost)
We add another bind-address entry to the config file.
Follow the steps below to fix the problem:
vi /etc/mysql/my.cnf – edit the my.cnf file
bind-address =192.168.100.22 — this is the Mysql server ip address.
Save the file and restart the mysql service: