Question: how to fix host is not allowed to connect to this mysql server?
Answer: Open up the file under 'etc/mysql/my.cnf'
Check for: ... 
Now access the MySQL Database on your actual server (say your remote address is 123.123.123.123 at port 3306 as user 'root' and I want to change permissions on database 'dataentry'. ... 
sudo service mysqld restart.