Is there a specific method in Java that checks whether a MySQL server is alive?
Assuming that you're running in Java 6 or higher, you can use the standard JDBC method Connection.isValid(int timeoutInSecs). Digging into the MySQL Connector/J source, the actual implementation uses com.mysql.jdbc.ConnectionImpl.pingInternal() to send a simple ping packet to the DB and returns true as long as a valid response is returned.