Re: Cursor copy_from with server crash

From: Marko Kreen <markokr(at)gmail(dot)com>
To: Grant McKenzie <mckenzig(at)optonline(dot)net>
Cc: "psycopg(at)postgresql(dot)org" <psycopg(at)postgresql(dot)org>
Subject: Re: Cursor copy_from with server crash
Date: 2011-09-30 05:54:14
Message-ID: CACMqXCJpJFw1TzCcUf8GjgaEoHAGoCj+Rxno9fVeN+EK8Yv_Mg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: psycopg

On Thu, Sep 29, 2011 at 5:36 PM, Grant McKenzie <mckenzig(at)optonline(dot)net> wrote:
> Using copy_from to insert a bunch of data. While this is running, the server host crashes and restarts. Getting a stacktrace from our client process, the copy_from never returned ( presumably no tcp close was received )
>
> Are there any common designs for protecting from host crashes, particularly when using copy_from?

TCP keepalive, see libpq params in 9.0+

--
marko

In response to

Browse psycopg by date

  From Date Subject
Next Message Marko Kreen 2011-09-30 05:56:50 Re: A successful SELECT 1; on failed connection
Previous Message Croepha 2011-09-29 19:34:31 A successful SELECT 1; on failed connection