Re: Merging postgresql.conf and postgresql.auto.conf

Поиск
Список
Период
Сортировка
От Sawada Masahiko
Тема Re: Merging postgresql.conf and postgresql.auto.conf
Дата
Msg-id CAD21AoCp731K87FRpN6pn9nDqZjZFJqx2SiL3byaSYS9YzTKcA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Merging postgresql.conf and postgresql.auto.conf  (Amit Kapila <amit.kapila16@gmail.com>)
Ответы Re: Merging postgresql.conf and postgresql.auto.conf  (Amit Kapila <amit.kapila16@gmail.com>)
Re: Merging postgresql.conf and postgresql.auto.conf  (David G Johnston <david.g.johnston@gmail.com>)
Список pgsql-hackers
On Fri, Jan 16, 2015 at 12:54 PM, Amit Kapila <amit.kapila16@gmail.com> wrote:
> On Thu, Jan 15, 2015 at 9:48 PM, Sawada Masahiko <sawada.mshk@gmail.com>
> wrote:
>> On Thu, Jan 15, 2015 at 2:02 PM, Amit Kapila <amit.kapila16@gmail.com>
>> wrote:
>> >
>> > One thought I have in this line is that currently there doesn't seem to
>> > be
>> > a way to know if the setting has an entry both in postgresql.conf and
>> > postgresql.auto.conf, if we can have some way of knowing the same
>> > (pg_settings?), then it could be convenient for user to decide if the
>> > value
>> > in postgresql.auto.conf is useful or not and if it's not useful then use
>> > Alter System .. Reset command to remove the same from
>> > postgresql.auto.conf.
>>
>> I think one way is that pg_settings has file name of variables,  But
>> It would not affect to currently status of postgresql.conf
>> So we would need to parse postgresql.conf again at that time.
>>
>
> Yeah that could be a possibility, but I think that will break the existing
> command('s) as this is the common infrastructure used for SHOW ..
> commands as well which displays the guc value that is used by
> current session rather than the value in postgresql.conf.

You're right.
pg_setting and SHOW command use value in current session rather than
config file.
It might break these common infrastructure.

>
> I don't know how appealing it would be to others, but a new view
> like pg_file_settings which would display the settings in file could
> be meaningful for your need.
>
> Another way is user can do pg_reload_conf() to see the latest
> values (excluding values for server startup time parameters).
>

I prefer the former. Because the latter would not handle all guc
variables as you said.
The new view like pg_file_setting has guc variable and config file
which has corresponding guc variable.
It would be helpful view for like ALTER SYSTEM ... RESET and that
command might be beneficial feature for user who want to manage
configuration file manually, I would like to propose them.

Regards,

-------
Sawada Masahiko



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Safe memory allocation functions
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: Safe memory allocation functions