Re: Patch for 9.1: initdb -C option
От | KaiGai Kohei |
---|---|
Тема | Re: Patch for 9.1: initdb -C option |
Дата | |
Msg-id | 4C463C38.20703@ak.jp.nec.com обсуждение исходный текст |
Ответ на | Re: Patch for 9.1: initdb -C option ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>) |
Список | pgsql-hackers |
(2010/07/21 7:33), Kevin Grittner wrote: > David Christensen<david@endpoint.com> wrote: >> On Jul 20, 2010, at 5:00 PM, Kevin Grittner wrote: > >>> my shop has chosen to never touch the default postgresql.conf >>> file any more, beyond adding one line to the bottom of it which >>> is an include directive, to bring in our overrides. > >> So you'll now issue: >> >> $ initdb ... -C 'include localconfig.conf' ? :-) > > Yeah, that would cover us. I'm wondering if it is flexible enough > to serve everyone else so well. I hesitate to suggest it, but > perhaps it would, in combination with the include directive > supporting a directory name to mean all files in the directory? Or > maybe if it supported wildcards? > I reminded that David introduced the following example as a usage of this feature. $ for cluster in 1 2 3 4 5 6; do initdb -D data$cluster -C "port = 1234$cluster" \ -C 'max_connections = 10' \ -C shared_buffers=1M; done In this case, it tries to set up six database clusters with constant max_connections and shared_buffers, but individual port numbers for each database clusters. Even if we support include directive here, it may not help to describe the postgresql.conf with a smart way. Then, how about the Itagaki-san's suggestion? Itagaki-san suggested: | > Enclosed is a patch to add a -C option to initdb to allow you to easily | > append configuration directives to the generated postgresql.conf file | Why don't you use just "echo 'options' >> $PGDATA/postgresql.conf" ? | Could you explain where the -C options is better than initdb + echo? As long as you don't need any special configuration during the initial setting up launched by initdb, indeed, it seems to me we can edit the postgresql.conf later. Thanks, -- KaiGai Kohei <kaigai@ak.jp.nec.com>
В списке pgsql-hackers по дате отправления: