Re: SQL command to edit postgresql.conf, with comments

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Josh Berkus <josh(at)agliodbs(dot)com>, Darren Duncan <darren(at)darrenduncan(dot)net>, postgres hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: SQL command to edit postgresql.conf, with comments
Date: 2010-10-13 13:13:29
Message-ID: AANLkTi=WHcDHGYB=epeeXZGw8-rUSR=ODaLpudXdc7+q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Oct 13, 2010 at 3:41 AM, Dimitri Fontaine
<dimitri(at)2ndquadrant(dot)fr> wrote:
> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
>> I agree with Josh's proposal: keep mechanically-generated settings in a
>> separate file, and don't even pretend to allow comments to be kept there.
>
> And then, when you SET PERMANENT knob TO value (or whatever the syntax
> is), you never know what value is selected at next startup or SIGHUP.
>
> I know I'm alone on this, but I much prefer the all-machine-friendly
> proposal that still makes it possible to hand-edit the files.

You're not alone on this at all: I agree 100%. I don't like your
proposed syntax, but I completely agree with your concern. I don't
see what's wrong with having the initial contents of postgresql.conf
look like this (these are the settings that are uncommented by default
on my machine):

# type "man postgresql.conf" for help on editing this file
max_connections = 100
shared_buffers = 32MB
datestyle = 'iso, mdy'
lc_messages = 'en_US.UTF-8'
lc_monetary = 'en_US.UTF-8'
lc_numeric = 'en_US.UTF-8'
lc_time = 'en_US.UTF-8'
default_text_search_config = 'pg_catalog.english'

When you type 'man postgresql.conf' it can tell you all of the things
that are currently in the file as comments. It's just that they'll be
in a man page rather in the file itself. I don't see what's bad about
that.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2010-10-13 13:27:34 Re: Slow count(*) again...
Previous Message Greg Smith 2010-10-13 13:02:21 Re: Slow count(*) again...