From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Peter Eisentraut <peter_e(at)gmx(dot)net> |
Cc: | Ray Stell <stellr(at)vt(dot)edu>, pgsql-general(at)postgresql(dot)org |
Subject: | Re: pg_upgrade -u |
Date: | 2013-05-29 15:17:24 |
Message-ID: | 20130529151724.GA32690@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general pgsql-hackers |
On Wed, May 29, 2013 at 09:42:12AM -0400, Peter Eisentraut wrote:
> On 5/21/13 2:41 PM, Bruce Momjian wrote:
> > I have thought about this and there are potentially several options
> > specified to pg_upgrade that could be passed into scripts:
> >
> > -O, --new-options=OPTIONS new cluster options to pass to the server
> > -P, --new-port=NEWPORT new cluster port number (default 50432)
> > -u, --user=NAME cluster superuser (default "root")
> >
> > However, if we pass these items into the scripts, we then force these
> > values to be used, even if the user wants to use a different value. It
> > is a balance between supplying defaults vs. requiring the user to supply
> > or change the values used during the ugprade.
> >
> > At this point, I have favored _not_ supplying defaults in the script.
> > Do you have an alternative argument in favor of supplying defaults?
>
> You could put environment variable assignments at the top of the script,
> so they are easy to change or remove. But it seems to me the values
> should be in there somehow.
Yes, that was another option, though I am worried that I am going to
start getting script-specific, no? Can I just do this:
PGUSER="postgres"
export PGUSER
vacuumedb -U "$PGUSER"
Is that portable? I know I can't do:
export PGUSER="postgres"
as older shells can't process that. What about -P? Do I pass that too?
I now realize we can't pass -O.
This is all easy to do for 9.4 if we can just agree on it.
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ It's impossible for everything to be true. +
From | Date | Subject | |
---|---|---|---|
Next Message | Vick Khera | 2013-05-29 15:51:03 | Re: foreign key to multiple tables depending on another column's value |
Previous Message | Bruce Momjian | 2013-05-29 15:07:02 | Re: [GENERAL] pg_upgrade -u |
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2013-05-29 15:19:33 | Re: fallocate / posix_fallocate for new WAL file creation (etc...) |
Previous Message | Bruce Momjian | 2013-05-29 15:07:02 | Re: [GENERAL] pg_upgrade -u |