From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: vacuumdb: don't prompt for passwords over and over |
Date: | 2015-11-12 21:22:26 |
Message-ID: | E1ZwzK6-0004n4-EX@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
vacuumdb: don't prompt for passwords over and over
Having the script prompt for passwords over and over was a preexisting
problem when it processed multiple databases or when it processed
multiple analyze stages, but the parallel mode introduced in commit
a179232047 made it worse.
Fix the annoyance by keeping a copy of the password used by the first
connection that requires one. Since users can (currently) only have a
single password, there's no need for more complex arrangements (such as
remembering one password per database).
Per bug #13741 reported by Eric Brown. Patch authored and
cross-reviewed by Haribabu Kommi and Michael Paquier, slightly tweaked
by Álvaro Herrera.
Discussion: http://www.postgresql.org/message-id/20151027193919.931.54948@wrigleys.postgresql.org
Backpatch to 9.5, where parallel vacuumdb was introduced.
Branch
------
REL9_5_STABLE
Details
-------
http://git.postgresql.org/pg/commitdiff/5094da99b901df42580b6e7494d036ee4be9eb81
Modified Files
--------------
src/bin/scripts/clusterdb.c | 2 +-
src/bin/scripts/common.c | 39 +++++++++++++++----------
src/bin/scripts/common.h | 4 +--
src/bin/scripts/createlang.c | 8 ++---
src/bin/scripts/createuser.c | 4 +--
src/bin/scripts/droplang.c | 8 ++---
src/bin/scripts/dropuser.c | 4 +--
src/bin/scripts/reindexdb.c | 8 ++---
src/bin/scripts/vacuumdb.c | 66 +++++++++++++++++++++++++++++++++++-------
9 files changed, 98 insertions(+), 45 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2015-11-13 01:24:46 | Re: pgsql: libpq: Notice errors a backend may have sent just before dying. |
Previous Message | Robert Haas | 2015-11-12 19:59:54 | pgsql: Move each SLRU's lwlocks to a separate tranche. |