Created
April 29, 2012 18:30
-
-
Save house9/2552481 to your computer and use it in GitHub Desktop.
Postgres Disconnect
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# replace your_db with the name of your database | |
psql postgres -c "select pg_terminate_backend(procpid) from pg_stat_activity where datname='your_db';" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment