From 18b286f3e3317c26f27ead1dea8be23c63a7ef2a Mon Sep 17 00:00:00 2001 From: Bruce Momjian Date: Tue, 15 Apr 2008 13:55:12 +0000 Subject: Add pg_terminate_backend() to allow terminating only a single session. --- doc/src/sgml/func.sgml | 19 +++++++++++++++---- doc/src/sgml/runtime.sgml | 9 ++++++++- 2 files changed, 23 insertions(+), 5 deletions(-) (limited to 'doc/src') diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index d2af5e63ee8..995d1ae9d35 100644 --- a/doc/src/sgml/func.sgml +++ b/doc/src/sgml/func.sgml @@ -1,4 +1,4 @@ - + Functions and Operators @@ -11848,6 +11848,9 @@ SELECT set_config('log_statement_stats', 'off', false); pg_cancel_backend + + pg_terminate_backend + pg_reload_conf @@ -11883,6 +11886,13 @@ SELECT set_config('log_statement_stats', 'off', false); boolean Cancel a backend's current query + + + pg_terminate_backend(pid int) + + boolean + Terminate a backend + pg_reload_conf() @@ -11907,9 +11917,10 @@ SELECT set_config('log_statement_stats', 'off', false); - pg_cancel_backend sends a query cancel - (SIGINT) signal to a backend process identified by - process ID. The process ID of an active backend can be found from + pg_cancel_backend and pg_terminate_backend + send a query cancel (SIGINT) signal to a backend process + identified by process ID. The + process ID of an active backend can be found from the procpid column in the pg_stat_activity view, or by listing the postgres processes on the server with diff --git a/doc/src/sgml/runtime.sgml b/doc/src/sgml/runtime.sgml index 1c799d8965b..c5222440fc8 100644 --- a/doc/src/sgml/runtime.sgml +++ b/doc/src/sgml/runtime.sgml @@ -1,4 +1,4 @@ - + Operating System Environment @@ -1372,6 +1372,13 @@ $ kill -INT `head -1 /usr/local/pgsql/data/postmaster.pid` + + + To terminate a session while allowing other sessions to continue, use + pg_terminate_backend() () rather than sending a signal + to the child process. + -- cgit v1.2.3