[Solved] ‘PDOException’ with message ‘SQLSTATE[HY000] [2002] No route to host

I am facing with this problem today, while trying to connect to a remote mysql on a network. Framework used Laravel 5.3. I have configured properly the .env file with exact credentials. Yesterday was working fine.

Solution #1:

It seems, that you have a network problem. Usually on a network ip changes from time to time. Please check the IP of the remote pc or computer on the network. If IP has changed, update again the .env file. Good luck.

Respondent: Dean Gite

The answers/resolutions are collected from stackoverflow, are licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0 .

Leave a Reply

Your email address will not be published.