From: | "Jaime Casanova" <systemguards(at)gmail(dot)com> |
---|---|
To: | "Edwin Perez Lozano" <edwinandperez(at)gmail(dot)com> |
Cc: | pgsql <pgsql-es-ayuda(at)postgresql(dot)org> |
Subject: | Re: Cerrar conexion con el servidor postgres |
Date: | 2007-07-14 20:27:30 |
Message-ID: | c2d9e70e0707141327x38cb0173of61f8ae9a276a323@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-es-ayuda |
On 7/14/07, Edwin Perez Lozano <edwinandperez(at)gmail(dot)com> wrote:
> El sáb, 14-07-2007 a las 14:26 +0000, Jaime Casanova escribió:
> > desde psql
> > \q
>
> Hola Jaime.
>
>
> Gracias por la info, pero creo que me explique mal, no quiero cerrar la
> conexion desde algun lenguaje de programacion, sino realizar lo
> siguiente:
>
> # select datid, procpid, usename, waiting,client_addr, current_query
> from pg_stat_activity where client_addr <> '127.0.0.1';
>
>
> y utilizar alguna metodo para cerrar la conexion del cliente con IP
> 192.168.2.13 (procpid 13285)
> una funcion interesante es pg_cancel_backend(pid int) pero esta solo me
> termina la ejecucion del current_query y quisiera saber si existe un
> metodo que cierre la conexion o estoy WTF?¿
>
y para que querrias hacer eso? si no quieres que alguien se conecte,
quitale el permiso en pg_hba.conf.
en 8.3 tambien podras quitarle el permiso desde SQL: REVOKE CONNECT
que tratas de lograr?
--
Atentamente,
Jaime Casanova
"Programming today is a race between software engineers striving to
build bigger and better idiot-proof programs and the universe trying
to produce bigger and better idiots.
So far, the universe is winning."
Richard Cook
From | Date | Subject | |
---|---|---|---|
Next Message | WILLIAM PARRA | 2007-07-14 20:27:32 | java.sql.SQLException: Error in allocating a connection |
Previous Message | Ernesto Quiñones | 2007-07-14 20:14:13 | leyendo las estructuras del postgresql |