Re: [PATCH] Cleanup of GUC units code

Поиск
Список
Период
Сортировка
От Alvaro Herrera
Тема Re: [PATCH] Cleanup of GUC units code
Дата
Msg-id 20080903201946.GI4114@alvh.no-ip.org
обсуждение исходный текст
Ответ на Re: [PATCH] Cleanup of GUC units code  (Hannu Krosing <hannu@2ndQuadrant.com>)
Список pgsql-hackers
Hannu Krosing escribió:
> On Wed, 2008-09-03 at 13:48 -0400, Alvaro Herrera wrote:

> > I think the energy wasted in this discussion would be better spent in
> > working a the check-the-config-file feature.
> 
> What kind of checks do you have in mind. Would this be something that
> works at restart, does the check and continues with old settings if new
> file would not load ?

This was discussed in some other thread.  No, the idea is that before
you do a reload, you run some function or invoke postmaster with certain
arguments, and it checks the config file and it says "this is OK" or
"there are errors here and here".  The check can be run even if the
server is already running.  That way you can just run it just before a
reload or restart.


> > That would equally solve
> > this problem, as well as many others.
> 
> AFAIK the config file is checked now, and if the check fails, the
> database won't start.

... which is not ideal.  Obviously it doesn't make much sense to run the
check if the server is already down, because you'll immediately know
that it won't come up just by trying to start it up.

(However, maybe it would be better for the init script to run the check
anyway, and report the error to stderr where the user running the script
can read it directly instead of having to go check the postmaster log
which could be sitting somewhere else.)

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


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

Предыдущее
От: Joshua Drake
Дата:
Сообщение: Re: [PATCH] Cleanup of GUC units code
Следующее
От: "Kevin Grittner"
Дата:
Сообщение: Re: IN vs EXISTS equivalence