Postgres.app Could not start on port 5432

后端 未结 24 1603
暗喜
暗喜 2021-01-29 22:24

I\'m using http://postgresapp.com. In the menubar it gives the error \" Could not start on port 5432.\" Similarly if I try to start the server from the terminal, I get:

24条回答
  •  忘掉有多难
    2021-01-29 22:56

    I had the same issues:

    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"?

    In my case it was a corrupt host file on my mac. I was missing:

    127.0.0.1   localhost
    

    A quick easy way to check is to open terminal and type:

    ping localhost
    

    or:

    scutil -r localhost

    More info here Hope it helps.

提交回复
热议问题