american-ninja-warrior
american-ninja-warrior

Reputation: 8235

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

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?

Upvotes: 3

Views: 4194

Answers (1)

isank-a
isank-a

Reputation: 1675

Can be done using pg_ctl

pg_ctl stop -D <path to postgres data dir>

Example

pg_ctl stop -D ~/Postgres/pg96/data

Upvotes: 4

Related Questions