Test the MySQL connection before doing anything database related