agora inbox for pgsql-interfaces@postgresql.org  
help / color / mirror / Atom feed
From: Greg Sabino Mullane <greg@turnstep.com>
To: pgsql-interfaces@postgresql.org
Subject: Re: Problem when forking
Date: Mon, 23 Mar 2015 20:02:47 -0000
Message-ID: <2ec30f86c6dae08c20fdf53aa3ce20f0@biglumber.com> (raw)
In-Reply-To: <CANs8QJYUu4QYpGV963_xdBjX+gUWAMFct_-At80KtvzwHdqzqg@mail.gmail.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-interfaces>


-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160


> I am seeing too many messages like "unexpected EOF on client connection".
> I've made a reasearch and I know the reason: I have processes that fork and
> don't close the connection causing those warnings.
>
> My questions is: is there a way to avoid that behavior beside of closing
> the connection before forking?

You can fork, you just have to make sure one side keeps talking to Postgres 
like normal, and the other should pretend Postgres is not there. It 
should also not do anything that would affect the first connection.

In general, it is a really good rule to fork *then* connect.

- -- 
Greg Sabino Mullane greg@turnstep.com
End Point Corporation http://www.endpoint.com/
PGP Key: 0x14964AC8 201503231601
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
-----BEGIN PGP SIGNATURE-----

iEYEAREDAAYFAlUQcUQACgkQvJuQZxSWSsh6eACdHvemvFLrV3VIZtECAOZB6gjX
BjoAoKGOoKc2yKDAfi5M2siDMMMjazaC
=kV9C
-----END PGP SIGNATURE-----




-- 
Sent via pgsql-interfaces mailing list (pgsql-interfaces@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-interfaces



view thread (2+ messages)

Message-ID: <2ec30f86c6dae08c20fdf53aa3ce20f0@biglumber.com>
Permalink:  ../2ec30f86c6dae08c20fdf53aa3ce20f0@biglumber.com/
Also on:    postgresql.org/message-id/2ec30f86c6dae08c20fdf53aa3ce20f0@biglumber.com

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-interfaces@postgresql.org
  Cc: greg@turnstep.com
  Subject: Re: Problem when forking
  In-Reply-To: <2ec30f86c6dae08c20fdf53aa3ce20f0@biglumber.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox