PostgreSQL's statistics collector is a subsystem that supports collection and reporting of information about server activity
Sample below to identify the procid for database cmdbuild:
postgres=# select * from pg_stat_activity where datname='cmdbuild';
datid | datname | procpid | usesysid |
44867 | cmdbuild | 2467 | 16384 |
44867 | cmdbuild | 2468 | 16384 |
(2 rows)
postgres=# select pg_terminate_backend(procpid) from pg_stat_activity where datname='cmdbuild';
pg_terminate_backend
----------------------
t
t
(2 rows)
postgres=# DROP DATABASE cmdbuild;
DROP DATABASE
No comments:
Post a Comment