Re: Explicit configuration file

Поиск
Список
Период
Сортировка
От mlw
Тема Re: Explicit configuration file
Дата
Msg-id 3C14B94F.66790A8@mohawksoft.com
обсуждение исходный текст
Ответ на Re: Explicit configuration file  (Peter Eisentraut <peter_e@gmx.net>)
Ответы Re: Explicit configuration file  (Peter Eisentraut <peter_e@gmx.net>)
Список pgsql-hackers
Peter Eisentraut wrote:
> 
> mlw writes:
> 
> > I have added the option of explicitly specifying a postgresql.conf (-C) file on
> > the command line. I have also added two config file entries:
> >
> > pghbaconfig, and pgdatadir.
> >
> > "pghbaconfig" allows multiple different databases running on the same machine
> > to use the same hba file, rather than the hard coded $PGDATA/pg_hba.conf.
> 
> That could be mildly useful, although symlinks make this already possible,
> and a bit clearer, IMHO.

On systems which support symlinks, yes. 

Also, a system should be "self documenting" i.e. one should be able to put
clues to why certain things were done. Symlinks allow one to do something, yes,
but if I leave the company, someone besides me should be able to administrate
the system I leave behind. 

Don't you consider symlinks as a kind of a hack around a basic flaw in the
configuration process? Shouldn't the configuration file let you completely
specify how your system is configured? 


> 
> > "pgdatadir" works with the explicit configuration file so that the data
> > directory can be specified in the configuration file, not on the command line
> > or environment.
> 
> So you exchange having to specify the data directory with having to
> specify the configuration file which specifies the data directory.  This
> doesn't add any functionality, it only adds one more indirection.

Yes and no. There is an underlying methodology to most unix server programs,
the configuration information goes in one place, and the data is in another.
For people used to PostgreSQL, I don't think they see how alien it is to people
that know how to admin UNIX, but not Postgres.

Think about named, sendmail, apache, dhcpd, sshd, etc. All these programs have
the notion that he configuration is separate from the working data. To see how
they are configured, you just go to the "/etc" or "/etc/pgsql" directory and
read the configuration file(s).

With postgres, you need to know where, and go to the data directory, as ROOT
(or the pg user) because you can't enter it otherwise, look at postgresql.conf,
do an "ls -l" to see which parts are symlinked and which are not. If you have
multiple PostgreSQL installations, you have to go to each directory and repeat
the process. (hyperbole, I know)

I just posted a reply to a message from Bruce, and in it I theorized that,
maybe, even "sysconfigdir" could point to where postgresql.conf would be
located by default.

I am not suggesting we change the default behavior of PostgreSQL, I am merely
suggesting that adding these features may make it more comfortable for the UNIX
admin.


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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: Third call for platform testing
Следующее
От: Michael Meskes
Дата:
Сообщение: Re: ECPG is okay again