Remote Server MySQL Connection

1). Open the my.cnf configuration file of MySQL of your Remote Server:
2). Comment the line :
#bind-address= 127.0.0.1
3). Now create a User :
Command:
CREATE USER 'username'@'ipaddress' IDENTIFIED BY 'password';

4). Now grant the permission to user:
Command:
GRANT ON *.* to 'username'@'ipaddress';

5). Now connect to your remote server mysql using the following command:
Command:
mysql -h ipaddress -u username -ppassword