Make sure your MySQL database is accessible through your network. If you are trying to access it on a local network, make sure your MySQL database has networking activated; many installations default to networking turned off. Make sure the the "skip-networking" option is off in either your my.conf or your server startup.

If you are trying to access an Amazon RDS MySQL server or other cloud based system, make sure your security settings permit you to access the database from your location. These services are typically filter out by ip address.

SSL connections can work over SSH tunnels. Situations that may necessitate this setup are SSL restricted MySQL databases that also have ip address connection restrictions. Note that over an SSH tunnel, SSL server identity must be OFF (because the tunneling is implicitly connecting to localhost and thus its name will never match the CN on the server certificate).