X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 9128B14B281F for ; Tue, 10 Aug 2004 10:41:18 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 83130-06 for ; Tue, 10 Aug 2004 13:41:07 +0000 (GMT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id 037EE14B280B for ; Tue, 10 Aug 2004 10:40:52 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i7ADeoiG086046 for ; Tue, 10 Aug 2004 13:40:50 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i7ADHDON077631 for pgsql-admin@postgresql.org; Tue, 10 Aug 2004 13:17:13 GMT X-Abuse-Report: abuse@ultrafeed.com Message-ID: Date: Tue, 10 Aug 2004 12:47:38 GMT Lines: 28 From: David Ecker Subject: Re: Killing Long running query or user session X-Newsgroups: comp.databases.postgresql.admin References: <065ed569632b300f0b33223972ec4e12@unlimited.ultrafeed.com> <4118AB80.5030209@bigfoot.com> User-Agent: KNode/0.7.7 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7Bit To: pgsql-admin@postgresql.org X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200408/64 X-Sequence-Number: 14459 Is there a posibilty to kick the session through a sql-statement? I don't want to give shell access to the postgreSQL administrator. Another posibility would be to block access to a database for a set of users/groups using sql only. Is there such a command? thx David Ecker Gaetano Mendola wrote: > David Ecker wrote: > >> How can I kill/stop a long running query or a complete user session using >> an superuser account? >> >> Thx >> David Ecker > > At my knowledge you have to kill SIGTERM the backedn that is managing the > connection. Do as super user "select * from pg_stat_activity", look at > the procpid that have to be killed and kill it. > > > > Regards > Gaetano Mendola