Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-05 Thread Boszormenyi Zoltan
2013-01-05 16:58 keltezéssel, Magnus Hagander írta: On Sat, Jan 5, 2013 at 3:41 PM, Magnus Hagander wrote: On Thu, Jan 3, 2013 at 1:33 PM, Boszormenyi Zoltan wrote: 2013-01-02 11:54 keltezéssel, Boszormenyi Zoltan írta: 2013-01-02 10:37 keltezéssel, Boszormenyi Zoltan írta: 2013-01-02 10:12

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-05 Thread Magnus Hagander
On Sat, Jan 5, 2013 at 3:41 PM, Magnus Hagander wrote: > On Thu, Jan 3, 2013 at 1:33 PM, Boszormenyi Zoltan wrote: >> 2013-01-02 11:54 keltezéssel, Boszormenyi Zoltan írta: >> >> 2013-01-02 10:37 keltezéssel, Boszormenyi Zoltan írta: >> >> 2013-01-02 10:12 keltezéssel, Magnus Hagander írta: >> At

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-05 Thread Magnus Hagander
On Thu, Jan 3, 2013 at 1:33 PM, Boszormenyi Zoltan wrote: > 2013-01-02 11:54 keltezéssel, Boszormenyi Zoltan írta: > > 2013-01-02 10:37 keltezéssel, Boszormenyi Zoltan írta: > > 2013-01-02 10:12 keltezéssel, Magnus Hagander írta: > Attached is the quotes-v2 patch, the function is renamed and > the

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-03 Thread Boszormenyi Zoltan
2013-01-02 11:54 keltezéssel, Boszormenyi Zoltan írta: 2013-01-02 10:37 keltezéssel, Boszormenyi Zoltan írta: 2013-01-02 10:12 keltezéssel, Magnus Hagander írta: On Wed, Jan 2, 2013 at 9:59 AM, Boszormenyi Zoltan > wrote: 2013-01-02 01:24 keltezéssel, Tom Lane írta

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-02 Thread Boszormenyi Zoltan
2013-01-02 10:37 keltezéssel, Boszormenyi Zoltan írta: 2013-01-02 10:12 keltezéssel, Magnus Hagander írta: On Wed, Jan 2, 2013 at 9:59 AM, Boszormenyi Zoltan > wrote: 2013-01-02 01:24 keltezéssel, Tom Lane írta: Boszormenyi Zoltan mailto:z...@cybertec.at>>

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-02 Thread Boszormenyi Zoltan
2013-01-02 10:12 keltezéssel, Magnus Hagander írta: On Wed, Jan 2, 2013 at 9:59 AM, Boszormenyi Zoltan > wrote: 2013-01-02 01:24 keltezéssel, Tom Lane írta: Boszormenyi Zoltan mailto:z...@cybertec.at>> writes: 2013-01-01 17:18 keltezéssel, Magnu

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-02 Thread Magnus Hagander
On Wed, Jan 2, 2013 at 9:59 AM, Boszormenyi Zoltan wrote: > 2013-01-02 01:24 keltezéssel, Tom Lane írta: > > Boszormenyi Zoltan writes: >> >>> 2013-01-01 17:18 keltezéssel, Magnus Hagander írta: >>> That way we can get around the whole need for changing memory allocation across all th

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-02 Thread Boszormenyi Zoltan
2013-01-02 01:24 keltezéssel, Tom Lane írta: Boszormenyi Zoltan writes: 2013-01-01 17:18 keltezéssel, Magnus Hagander írta: That way we can get around the whole need for changing memory allocation across all the frontends, no? Like the attached. Sure it's simpler but then the consistent look

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Tom Lane
Boszormenyi Zoltan writes: > 2013-01-01 17:18 keltezéssel, Magnus Hagander írta: >> That way we can get around the whole need for changing memory allocation >> across all the >> frontends, no? Like the attached. > Sure it's simpler but then the consistent look of the code is lost. > What about

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Boszormenyi Zoltan
2013-01-01 17:18 keltezéssel, Magnus Hagander írta: On Fri, Nov 30, 2012 at 10:13 AM, Boszormenyi Zoltan > wrote: Hi, now that PQconninfo() was committed, I rebased the subsequent patches. Actual code change was only in the last patch, to conform to th

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Magnus Hagander
On Tue, Jan 1, 2013 at 7:13 PM, Boszormenyi Zoltan wrote: > 2013-01-01 18:25 keltezéssel, Magnus Hagander írta: > > > On Fri, Nov 30, 2012 at 10:13 AM, Boszormenyi Zoltan wrote: > >> Hi, >> >> now that PQconninfo() was committed, I rebased the subsequent >> patches. Actual code change was only i

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Boszormenyi Zoltan
2013-01-01 18:25 keltezéssel, Magnus Hagander írta: On Fri, Nov 30, 2012 at 10:13 AM, Boszormenyi Zoltan > wrote: Hi, now that PQconninfo() was committed, I rebased the subsequent patches. Actual code change was only in the last patch, to conform to th

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Magnus Hagander
On Fri, Nov 30, 2012 at 10:13 AM, Boszormenyi Zoltan wrote: > Hi, > > now that PQconninfo() was committed, I rebased the subsequent > patches. Actual code change was only in the last patch, to > conform to the committed PQconninfo() API. > > I've applied a modified version of the "tar unification

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2013-01-01 Thread Magnus Hagander
On Fri, Nov 30, 2012 at 10:13 AM, Boszormenyi Zoltan wrote: > Hi, > > now that PQconninfo() was committed, I rebased the subsequent > patches. Actual code change was only in the last patch, to > conform to the committed PQconninfo() API. So, finally coming back to this one. What happened to Al

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Boszormenyi Zoltan
2012-11-21 15:29 keltezéssel, Tom Lane írta: Boszormenyi Zoltan writes: pg_basebackup needs pg_malloc() to call disconnect_and_exit(1) instead to quit cleanly and not leave an "unexpected EOF from client" message in the server log. Which is a macro at the moment, but has to be turned into a rea

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Tom Lane
Boszormenyi Zoltan writes: > pg_basebackup needs pg_malloc() to call disconnect_and_exit(1) > instead to quit cleanly and not leave an "unexpected EOF from client" > message in the server log. Which is a macro at the moment, but > has to be turned into a real function for the reasons below. man 2

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Alvaro Herrera
Boszormenyi Zoltan wrote: > 2012-11-21 14:19 keltezéssel, Alvaro Herrera írta: > >Boszormenyi Zoltan wrote: > > > >>The problem is that it calls pg_malloc() which is an executable-specific > >>function. Some of the bin/* executables define it as calling exit(1) > >>when malloc() returns NULL, some

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Boszormenyi Zoltan
2012-11-21 14:19 keltezéssel, Alvaro Herrera írta: Boszormenyi Zoltan wrote: The problem is that it calls pg_malloc() which is an executable-specific function. Some of the bin/* executables define it as calling exit(1) when malloc() returns NULL, some call it with exit(EXIT_FAILURE) which happe

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Alvaro Herrera
Boszormenyi Zoltan wrote: > The problem is that it calls pg_malloc() which is an executable-specific > function. Some of the bin/* executables define it as calling exit(1) > when malloc() returns NULL, some call it with exit(EXIT_FAILURE) > which happens to be 1 but still can be different from the

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-21 Thread Boszormenyi Zoltan
2012-11-20 20:32 keltezéssel, Boszormenyi Zoltan írta: 2012-11-20 17:03 keltezéssel, Boszormenyi Zoltan írta: 2012-11-18 17:20 keltezéssel, Magnus Hagander írta: Much of the tar stuff is very similar (I haven't looked to see if it's identical) to the stuff in backend/replication/basebackup.c.

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-20 Thread Boszormenyi Zoltan
2012-11-20 17:03 keltezéssel, Boszormenyi Zoltan írta: 2012-11-18 17:20 keltezéssel, Magnus Hagander írta: The whole tar writing part of the code needs a lot more comments. It's entirely unclear what the code does there. Why does the recovery.conf writing code need to be split up in multiple lo

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-20 Thread Boszormenyi Zoltan
2012-11-18 17:20 keltezéssel, Magnus Hagander írta: On Tue, Oct 23, 2012 at 5:08 PM, Magnus Hagander wrote: On Oct 23, 2012 4:52 PM, "Alvaro Herrera" wrote: Boszormenyi Zoltan escribió: Also, the check for conflict between -R and -x/-X is now removed. The documentation for option -R has ch

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-18 Thread Boszormenyi Zoltan
Hi, 2012-11-18 17:20 keltezéssel, Magnus Hagander írta: On Tue, Oct 23, 2012 at 5:08 PM, Magnus Hagander wrote: On Oct 23, 2012 4:52 PM, "Alvaro Herrera" wrote: Boszormenyi Zoltan escribió: Also, the check for conflict between -R and -x/-X is now removed. The documentation for option -R h

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-11-18 Thread Magnus Hagander
On Tue, Oct 23, 2012 at 5:08 PM, Magnus Hagander wrote: > > On Oct 23, 2012 4:52 PM, "Alvaro Herrera" wrote: >> >> Boszormenyi Zoltan escribió: >> >> > >>Also, the check for conflict between -R and -x/-X is now removed. >> > >> > The documentation for option -R has changed to reflect this and >>

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-23 Thread Magnus Hagander
On Oct 23, 2012 4:52 PM, "Alvaro Herrera" wrote: > > Boszormenyi Zoltan escribió: > > > >>Also, the check for conflict between -R and -x/-X is now removed. > > > > The documentation for option -R has changed to reflect this and > > there is no different error code 2 now: it would make the behaviou

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-23 Thread Alvaro Herrera
Boszormenyi Zoltan escribió: > >>Also, the check for conflict between -R and -x/-X is now removed. > > The documentation for option -R has changed to reflect this and > there is no different error code 2 now: it would make the behaviour > inconsistent between -Fp and -Ft. > > >>>The PQconninfo p

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-15 Thread Boszormenyi Zoltan
2012-10-14 22:31 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 22:26 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 22:23 keltezéssel, Boszormenyi Zoltan írta: Hi, 2012-10-14 18:41 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 18:02 keltezéssel, Fujii Masao írta: Thanks for updating

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
2012-10-14 22:26 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 22:23 keltezéssel, Boszormenyi Zoltan írta: Hi, 2012-10-14 18:41 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 18:02 keltezéssel, Fujii Masao írta: Thanks for updating the patch! On Sun, Oct 14, 2012 at 8:41 PM, Boszormenyi

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
2012-10-14 22:23 keltezéssel, Boszormenyi Zoltan írta: Hi, 2012-10-14 18:41 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 18:02 keltezéssel, Fujii Masao írta: Thanks for updating the patch! On Sun, Oct 14, 2012 at 8:41 PM, Boszormenyi Zoltan wrote: Backing up a standby server without -R

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
Hi, 2012-10-14 18:41 keltezéssel, Boszormenyi Zoltan írta: 2012-10-14 18:02 keltezéssel, Fujii Masao írta: Thanks for updating the patch! On Sun, Oct 14, 2012 at 8:41 PM, Boszormenyi Zoltan wrote: Backing up a standby server without -R preserves the original recovery.conf of the standby, it

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
2012-10-14 18:02 keltezéssel, Fujii Masao írta: Thanks for updating the patch! On Sun, Oct 14, 2012 at 8:41 PM, Boszormenyi Zoltan wrote: Backing up a standby server without -R preserves the original recovery.conf of the standby, it points to the standby's source server. Backing up a standby

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Fujii Masao
On Mon, Oct 15, 2012 at 12:57 AM, Boszormenyi Zoltan wrote: > 2012-10-11 02:02 keltezéssel, Fujii Masao írta: > >> On Thu, Oct 11, 2012 at 3:36 AM, Boszormenyi Zoltan >> wrote: >>> >>> 2012-10-10 18:23 keltezéssel, Fujii Masao írta: When tar output format is specified together with -R o

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Fujii Masao
Thanks for updating the patch! On Sun, Oct 14, 2012 at 8:41 PM, Boszormenyi Zoltan wrote: > Backing up a standby server without -R preserves the original recovery.conf > of the > standby, it points to the standby's source server. > > Backing up a standby server with -R overwrites the original rec

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
2012-10-11 02:02 keltezéssel, Fujii Masao írta: On Thu, Oct 11, 2012 at 3:36 AM, Boszormenyi Zoltan wrote: 2012-10-10 18:23 keltezéssel, Fujii Masao írta: When tar output format is specified together with -R option, recovery.conf is not included in base.tar. I think it should. Why? This patc

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-14 Thread Boszormenyi Zoltan
2012-10-12 22:21 keltezéssel, Robert Haas írta: On Wed, Oct 10, 2012 at 8:02 PM, Fujii Masao wrote: On Thu, Oct 11, 2012 at 3:36 AM, Boszormenyi Zoltan wrote: 2012-10-10 18:23 keltezéssel, Fujii Masao írta: When tar output format is specified together with -R option, recovery.conf is not inc

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-12 Thread Robert Haas
On Wed, Oct 10, 2012 at 8:02 PM, Fujii Masao wrote: > On Thu, Oct 11, 2012 at 3:36 AM, Boszormenyi Zoltan wrote: >> 2012-10-10 18:23 keltezéssel, Fujii Masao írta: >>> When tar output format is specified together with -R option, recovery.conf >>> is >>> not included in base.tar. I think it should

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Fujii Masao
On Thu, Oct 11, 2012 at 4:58 AM, Boszormenyi Zoltan wrote: > I was able to test it on OSX and I found my bug. Attached is the new code. > The problem was in conninfo_init(), the last entry in the filtered list was > not initialized to 0. It seems that for some reason, my Linux machine gave > me pr

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Fujii Masao
On Thu, Oct 11, 2012 at 3:36 AM, Boszormenyi Zoltan wrote: > 2012-10-10 18:23 keltezéssel, Fujii Masao írta: >> When tar output format is specified together with -R option, recovery.conf >> is >> not included in base.tar. I think it should. > > > Why? This patch only promises to write the recovery

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Boszormenyi Zoltan
2012-10-10 20:36 keltezéssel, Boszormenyi Zoltan írta: 2012-10-10 18:23 keltezéssel, Fujii Masao írta: On Wed, Oct 10, 2012 at 10:12 PM, Boszormenyi Zoltan wrote: Hi, thanks for the new review. 2012-10-10 08:58 keltezéssel, Amit Kapila írta: On Thursday, October 04, 2012 9:50 PM Boszormenyi

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Boszormenyi Zoltan
2012-10-10 18:23 keltezéssel, Fujii Masao írta: On Wed, Oct 10, 2012 at 10:12 PM, Boszormenyi Zoltan wrote: Hi, thanks for the new review. 2012-10-10 08:58 keltezéssel, Amit Kapila írta: On Thursday, October 04, 2012 9:50 PM Boszormenyi Zoltan 2012-10-04 16:43 keltezéssel, Tom Lane írta:

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Fujii Masao
On Wed, Oct 10, 2012 at 10:12 PM, Boszormenyi Zoltan wrote: > Hi, > > thanks for the new review. > > 2012-10-10 08:58 keltezéssel, Amit Kapila írta: >> >> On Thursday, October 04, 2012 9:50 PM Boszormenyi Zoltan >>> >>> 2012-10-04 16:43 keltezéssel, Tom Lane írta: >>> Boszormenyi Zoltan writ

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Boszormenyi Zoltan
Hi, thanks for the new review. 2012-10-10 08:58 keltezéssel, Amit Kapila írta: On Thursday, October 04, 2012 9:50 PM Boszormenyi Zoltan 2012-10-04 16:43 keltezéssel, Tom Lane írta: Boszormenyi Zoltan writes: Did you think about something like the attached code? Or rather this one, which fi

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-10 Thread Amit Kapila
On Thursday, October 04, 2012 9:50 PM Boszormenyi Zoltan > 2012-10-04 16:43 keltezéssel, Tom Lane írta: > > Boszormenyi Zoltan writes: > >>> Did you think about something like the attached code? > >> Or rather this one, which fixes a bug so fillPGconn() and > >> PQconninfo() are symmetric and work

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-04 Thread Boszormenyi Zoltan
2012-10-04 16:43 keltezéssel, Tom Lane írta: Boszormenyi Zoltan writes: Did you think about something like the attached code? Or rather this one, which fixes a bug so fillPGconn() and PQconninfo() are symmetric and work for "requiressl". That's incredibly ugly. I'm not sure where we should k

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-04 Thread Tom Lane
Boszormenyi Zoltan writes: >> Did you think about something like the attached code? > Or rather this one, which fixes a bug so fillPGconn() and PQconninfo() are > symmetric and work for "requiressl". That's incredibly ugly. I'm not sure where we should keep the "R" information, but shoehorning

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-04 Thread Boszormenyi Zoltan
2012-10-04 12:42 keltezéssel, Boszormenyi Zoltan írta: 2012-10-04 06:47 keltezéssel, Boszormenyi Zoltan írta: 2012-10-04 05:24 keltezéssel, Peter Eisentraut írta: On Wed, 2012-10-03 at 18:15 +0200, Boszormenyi Zoltan wrote: The second generation of this work is now attached and contains a new

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-04 Thread Boszormenyi Zoltan
2012-10-04 06:47 keltezéssel, Boszormenyi Zoltan írta: 2012-10-04 05:24 keltezéssel, Peter Eisentraut írta: On Wed, 2012-10-03 at 18:15 +0200, Boszormenyi Zoltan wrote: The second generation of this work is now attached and contains a new feature as was discussed and suggested by Magnus Hagande

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-03 Thread Boszormenyi Zoltan
2012-10-04 05:24 keltezéssel, Peter Eisentraut írta: On Wed, 2012-10-03 at 18:15 +0200, Boszormenyi Zoltan wrote: The second generation of this work is now attached and contains a new feature as was discussed and suggested by Magnus Hagander, Fujii Masao and Peter Eisentraut. So libpq has grown

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-03 Thread Peter Eisentraut
On Wed, 2012-10-03 at 18:15 +0200, Boszormenyi Zoltan wrote: > The second generation of this work is now attached and contains a new > feature as was discussed and suggested by Magnus Hagander, Fujii Masao > and Peter Eisentraut. So libpq has grown a new function: > > +/* return the connection opt

Re: [HACKERS] [PATCH] Make pg_basebackup configure and start standby [Review]

2012-10-03 Thread Boszormenyi Zoltan
Hi, first, thanks for the review. Comments are below. 2012-09-20 12:30 keltezéssel, Amit Kapila írta: On Sun, 01 Jul 2012 13:02:17 +0200 Boszormenyi Zoltan wrote: >attached is a patch that does $SUBJECT. >It's a usability enhancement, to take a backup, write >a minimalistic recovery.conf an