How do I stop (postgres.app) postgres cluster from command line

3.3k Views Asked by At

How do I stop a particular Postgres.app cluster without using the gui.

Instead of gui, I want to use bash/Terminal.app

stopping it via gui

I should also point out that, Postgres app has a menu like this

enter image description here

So if I do a kill, would the menu show an incorrect state?

1

There are 1 best solutions below

0
isank-a On BEST ANSWER

Can be done using pg_ctl

pg_ctl stop -D <path to postgres data dir>

Example

pg_ctl stop -D ~/Postgres/pg96/data