Postgres.app Could not start on port 5432

后端 未结 24 1103
暗喜
暗喜 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:53

    When trying to open the Postgres app was getting that same error regarding post 5432 (on Mac OSX 10.10.5)

    I did:

    $ lsof -i | grep LISTEN
    

    Saw which PID was running postgres at that port, did: $ killall {pid} and then $ brew uninstall postgres

    After that, restarted my Mac, and ran:

    $ lsof -i | grep LISTEN again just to make sure. Saw no postgres running anywhere and was able to open the Postgres app without getting that warning.

    Then I reinstalled postgres with $ brew install postgres

    ANOTHER OPTION:

    (I also tried this one time when the above approach didn't work and I could not kill any of the PID)

    $ ps auxw | grep post
    

    Saw a slew postgres processes, which I then sudo kill

    Everything working fine now.

提交回复
热议问题