BUG #4738: Cannot reconnect to shared memory

Started by Jonathan Barnhartabout 17 years ago2 messagesbugs
Jump to latest
#1Jonathan Barnhart
jdbarnhart@yahoo.com

The following bug has been logged online:

Bug reference: 4738
Logged by: Jonathan Barnhart
Email address: jdbarnhart@yahoo.com
PostgreSQL version: 8.3.7
Operating system: WinXP, Vista
Description: Cannot reconnect to shared memory
Details:

This bug seems to have been reintroduced between versions 8.3.4 and 8.3.7.
It is basically a race condition when the fork emulation for Windows is
used. The problem is that the side of the "fork" that creates the shared
memory to emulate the Unix fork is often executed AFTER the logic in the
"forked" process that connects to the shared memory.

The obvious thing that has to be done is to create the shared memory object
and THEN spawn the child processes. Unfortunately, the logic in that area
is not entirely straightforward with a number of dependancies.

I'm working on patching this, but so far I have had issues with screwing up
other order dependant code.

#2Bruce Momjian
bruce@momjian.us
In reply to: Jonathan Barnhart (#1)
Re: BUG #4738: Cannot reconnect to shared memory

Has there been any progress on this?

---------------------------------------------------------------------------

Jonathan Barnhart wrote:

The following bug has been logged online:

Bug reference: 4738
Logged by: Jonathan Barnhart
Email address: jdbarnhart@yahoo.com
PostgreSQL version: 8.3.7
Operating system: WinXP, Vista
Description: Cannot reconnect to shared memory
Details:

This bug seems to have been reintroduced between versions 8.3.4 and 8.3.7.
It is basically a race condition when the fork emulation for Windows is
used. The problem is that the side of the "fork" that creates the shared
memory to emulate the Unix fork is often executed AFTER the logic in the
"forked" process that connects to the shared memory.

The obvious thing that has to be done is to create the shared memory object
and THEN spawn the child processes. Unfortunately, the logic in that area
is not entirely straightforward with a number of dependancies.

I'm working on patching this, but so far I have had issues with screwing up
other order dependant code.

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

--
Bruce Momjian <bruce@momjian.us> http://momjian.us
EnterpriseDB http://enterprisedb.com

+ If your life is a hard drive, Christ can be your backup. +