There are a variety of reasons why this can happen, and rather than spell them all out with the hopes that one will stick, I'll refer you to http://dev.mysql.com/doc/mysql/en/can-not-connect-to-server.html in the MySQL Online Reference Manual.
By submitting your personal information, you agree that TechTarget and its partners may contact you regarding relevant content, products and special offers.
In a nutshell, make sure the server is running, make sure the post is not firewalled, and if connecting with unix sockets, make sure the socket file has permissions for writing.
Dig Deeper on Open source databases
Have a question for an expert?
Please add a title for your question
Get answers from a TechTarget expert on whatever's puzzling you.