From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | Stephen Frost <sfrost(at)snowman(dot)net> |
Cc: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>, Andres Freund <andres(at)2ndquadrant(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: Proposal for Allow postgresql.conf values to be changed via SQL [review]) |
Date: | 2013-08-20 15:14:38 |
Message-ID: | 20130820151438.GD6564@eldon.alvh.no-ip.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Stephen Frost escribió:
> * Amit Kapila (amit(dot)kapila16(at)gmail(dot)com) wrote:
> > So let me try to explain what I understood from above:
> >
> > 1. enable_alter_system a new GUC whose default value =off.
> > 2. Alter System will check this variable and return error (not
> > allowed), if this parameter is off.
> > 3. Now if user enables include directive in postgresql.conf, it will
> > enable Alter System as value of
> > enable_alter_system is on.
> > 4. User can run Alter System command to disable Alter System
> > "enable_alter_system = off".
> > Now even though include directive is enabled, but new Alter System
> > commands will not work, however
> > existing parameter's take into effect on restart/sighup.
>
> Yes. Not sure that it'd be terribly likely for a user to do that, but
> if they do it, so be it.
With this design, if you put enable_alter_system=off in auto.conf, there
is no way for the user to enable alter system again short of editing a
file in the data directory. I think this is one of the things that was
"forbidden" by policy; only files in the config directory needs to be
edited.
What I was proposing upthread is that enable_alter_system=off/on would
be present in postgresql.conf, and there is no include line for
auto.conf. That way, if the user wishes to enable/disable the feature,
they need to edit postgresql.conf to do so. ALTER SYSTEM doesn't offer
a way to disable itself. If ALTER SYSTEM is disabled via
enable_alter_system=off in postgresql.conf, the settings in auto.conf
are not read.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Sawada Masahiko | 2013-08-20 15:15:39 | Re: Parsing bool type value |
Previous Message | Stephen Frost | 2013-08-20 15:11:16 | Re: ALTER SYSTEM SET command to change postgresql.conf parameters (RE: Proposal for Allow postgresql.conf values to be changed via SQL [review]) |