Re: -Wformat-zero-length - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: -Wformat-zero-length
Date
Msg-id 20120814224332.GA28155@momjian.us
Whole thread Raw
In response to Re: -Wformat-zero-length  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: -Wformat-zero-length
List pgsql-hackers
On Tue, Aug 14, 2012 at 05:56:39PM -0400, Tom Lane wrote:
> Peter Eisentraut <peter_e@gmx.net> writes:
> > On 8/10/12 7:48 PM, Dimitri Fontaine wrote:
> >> What about having single user mode talk fe/be protocol, and talk to it via a UNIX pipe, with pg_upgrade starting
thesingle user backend as a subprocess?
 
> 
> > I think that's essentially equivalent to starting the server on a 
> > Unix-domain socket in a private directory.  But that has been rejected 
> > because it doesn't work on Windows.
> 
> > The question in my mind is, is there some other usable way on Windows 
> > for two unrelated processes to communicate over file descriptors in a 
> > private and secure way?
> 
> You're making this unnecessarily hard, because there is no need for the
> two processes to be unrelated.
> 
> The implementation I'm visualizing is that a would-be client (think psql
> or pg_dump, though the code would actually be in libpq) forks off a
> process that becomes a standalone backend, and then they communicate
> over a pair of pipes that were created before forking.  This is
> implementable on any platform that supports Postgres, because initdb
> already relies on equivalent capabilities.

I think the big question is whether we need to modify every binary that
pg_upgrade executes to underestand this pipe communication method.

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + It's impossible for everything to be true. +



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: -Wformat-zero-length
Next
From: Michael Braun
Date:
Subject: Re: superusers are members of all roles?