Subject: Re: Postgresql Data Directories
To: D'Arcy J.M. Cain <darcy@NetBSD.org>
From: Patrick Welche <prlw1@newn.cam.ac.uk>
List: tech-pkg
Date: 02/22/2005 15:27:57
On Sun, Feb 20, 2005 at 07:42:08AM -0500, D'Arcy J.M. Cain wrote:
> On Sun, 20 Feb 2005 10:09:12 +0100
> Marc Recht <marc@geht.de> wrote:
> > > I'm wondering if the postgresql packages ought not use the version
> > > number in the data directory, e.g.: ${pgsql_home}/data80 instead of
> > > ${pgsql_home}/data. This would ensure that postgresql never tries to
> > 
> > Yes, I'm planning to do this for pgsql packages.
> 
> I'm not so sure this is useful.  It seems to me that expert users will
> know how to handle this and will have their own way of laying out data
> directories and will just have to work around this.  On the other hand,
> people that don't fully understand will need to learn this anyway and
> this could be an extra surprise that they won't be able to figure out by
> reading the PostgreSQL docsumentation since it is a NetBSD modification.
>  Certainly we can never handle every possible situation and someone will
> be confused.
> 
> > > read data not compatable with that version, and also avoid the risk
> > > of accidently damaging or deleting one's data after upgrading.
> 
> For quite a while now PostgreSQL has been safe in this regard.  It won't
> initdb a new database over an existing one and it won't start an
> incompatible one.  It explains this tersely in the error messages and
> the site explains in more detail what to do in those cases.

Good point..

Patrick