I am having this issue third or forth time where after restarting my Mac (Yosemite and same thing with previous OSX version) postgres server doesn't start. I had installed my postgres following [this](https://www.codefellows.org/blog/three-battle-tested-ways-to-install-postgresql) link. Any idea why this consistently occurs after every restart? 

typing `psql` it gives

```
psql: could not connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

```