Re: Problem with reading startup packet after fork

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Problem with reading startup packet after fork
Date: 2001-06-19 18:41:12
Message-ID: Pine.LNX.4.30.0106192028040.724-100000@peter.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut writes:

> I think there will be a race condition around the time of a database
> shutdown. After a new child process is created, the system may go into
> shutdown mode. However, there is a window where the child won't know
> this, because the signal is blocked and/or not set up yet. Note that we
> cannot check for shutdown before forking the child because we won't know
> yet whether the incoming packet is actually a connection request. We
> wouldn't want to send back an error in response to a cancel request, for
> example.

Well, cancel that. The child will see the shutdown because the signal is
blocked around the fork. So unless anyone has issues with the latest
patch I posted I will check it in in slightly clean-up form.

--
Peter Eisentraut peter_e(at)gmx(dot)net http://funkturm.homeip.net/~peter

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2001-06-19 18:58:05 Re: AW: Re: [SQL] behavior of ' = NULL' vs. MySQL vs. Stand ards
Previous Message P. Dwayne Miller 2001-06-19 18:26:56 Primary Key