Re: [COMMITTERS] pgsql-server/src backend/tcop/postgres.cbacke - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: [COMMITTERS] pgsql-server/src backend/tcop/postgres.cbacke
Date
Msg-id 200208131455.g7DEt3w06247@candle.pha.pa.us
Whole thread Raw
In response to Re: [COMMITTERS] pgsql-server/src backend/tcop/postgres.cbacke  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Yea, the problem with postgresql.conf is that we don't have any
automatic modifications of that file, and I don't think we want to start
just to avoid symlinks.

I personally like symlinks too.  I use them all the time.  What is the
problem with them, exactly?  Can someone show me some commands that
cause problems?

And the problem with a separate file is that when the move pg_xlog, it
isn't going to be obvious what they need to change to find the new
directory.  Of course, they could just create a symlink and leave the
file unchanged.

Aside from the arg bloat problem, the real danger is that someone is
going to forget PGDATA and PGXLOG, try to start the postmaster, add -D
for PGDATA, then when they see that they need PGXLOG, they may just
create data/pg_xlog as an empty directory and start the postmaster. 
That is a very real possibility.  I just tried it and it does complain
about the missing checkpoint records so maybe it isn't as bad as I
thought, but still, it opens a place for error where none existed
before.

---------------------------------------------------------------------------

Tom Lane wrote:
> Oliver Elphick <olly@lfix.co.uk> writes:
> > On Tue, 2002-08-13 at 14:24, Tom Lane wrote:
> >> But there's more than one way to record the xlog location in the data
> >> directory.  If you don't like a symlink, what of putting it in
> >> postgresql.conf as a postmaster-start-time-only config option?
> 
> > Please don't!
> 
> > The Debian package at least provides a default postgresql.conf and it
> > will be all too easy for someone installing an updated package to let
> > the default file overwrite the existing configuration.  That could be
> > disastrous.
> 
> Ouch.  That's a mighty good point ... although if we were to implement
> Marc's idea of matching signature files, we'd certainly catch the error.
> 
> If we didn't, we'd need to use a separate, one-purpose config file that
> just records the xlog location.  Curiously enough, that seems to me to
> be exactly what a symlink does, except that the symlink is OS-level code
> rather than something we have to write for ourselves.  So I'm back to
> thinking that a symlink is a perfectly respectable answer.
> 
>             regards, tom lane
> 
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
> 

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [COMMITTERS] pgsql-server/src
Next
From: Tom Lane
Date:
Subject: Re: [GENERAL] Linux Largefile Support In Postgresql RPMS