Re: BUG #2576: tcp_keepalive doesn't work

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Fujii Masao" <fujii(dot)masao(at)oss(dot)ntt(dot)co(dot)jp>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #2576: tcp_keepalive doesn't work
Date: 2006-08-15 13:30:16
Message-ID: 2407.1155648616@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Fujii Masao" <fujii(dot)masao(at)oss(dot)ntt(dot)co(dot)jp> writes:
> I found an error that tcp_keepalive doesn't work.

You seem to have a misunderstanding of what tcp_keepalive is for. It
does not kill a backend that is in the midst of a query. A backend will
terminate when it is waiting for a client command and it sees that the
connection has been lost --- which is what a TCP timeout will cause to
happen. But your example backends are not waiting for client commands.

If you want backends to abort live queries before they finish, use
statement_timeout.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Luiz Henrique 2006-08-15 13:50:29 Re: referential integrity violation - key referenced from
Previous Message Fujii Masao 2006-08-15 08:12:33 BUG #2576: tcp_keepalive doesn't work