I have a server with Rackspace. I want to access the database from my local machine command line.
I tried like:
mysql -u username -h my.application.com
try telnet 3306
. If it doesn't open connection, either there is a firewall setting or the server isn't listening (or doesn't work).
run netstat -an
on server to see if server is up.
It's possible that you don't allow remote connections.
See http://www.cyberciti.biz/tips/how-do-i-enable-remote-access-to-mysql-database-server.html