How to solve Failed: No such file or directory problem

This almost always means you are using the database hostname localhost instead of the value you’re supposed to be using, which is displayed in the client area and control panel.