Skip site navigation (1) Skip section navigation (2)

Re: pg_ctl idempotent option

From: Bruce Momjian <bruce(at)momjian(dot)us>
To: Simon Riggs <simon(at)2ndQuadrant(dot)com>
Cc: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>,Peter Eisentraut <peter_e(at)gmx(dot)net>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pg_ctl idempotent option
Date: 2013-01-29 02:29:35
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
On Mon, Jan 28, 2013 at 03:40:08PM +0000, Simon Riggs wrote:
> On 14 January 2013 15:29, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> wrote:
> > Tom Lane wrote:
> >> Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> >> > Here is a patch to add an option -I/--idempotent to pg_ctl, the result
> >> > of which is that pg_ctl doesn't error on start or stop if the server is
> >> > already running or already stopped.
> >>
> >> Idempotent is a ten-dollar word.  Can we find something that average
> >> people wouldn't need to consult a dictionary to understand?
> >
> > --no-error perhaps?
> I think --force  would be the accepted way to ensure something happens
> as specified
> Mind you, I'm not sure I see the value in throwing an error if the
> server is in the desired state already. Who actually wants that
> behaviour? Can't we just change the behaviour? Existing scripts would
> still work, since we are simply skipping an error.

pg_upgrade uses that to find out of the server was already running or if
we started it.  This is to start the server to remove the file.  Also, no one has explained how not knowing if -o
options were used was a safe.

  Bruce Momjian  <bruce(at)momjian(dot)us>

  + It's impossible for everything to be true. +

In response to


pgsql-hackers by date

Next:From: Robert HaasDate: 2013-01-29 02:34:41
Subject: Re: Enabling Checksums
Previous:From: Andres FreundDate: 2013-01-29 01:57:32
Subject: Re: logical changeset generation v4

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group