Re: tablespaces for temporary files - Mailing list pgsql-hackers

From Tom Lane
Subject Re: tablespaces for temporary files
Date
Msg-id 16012.1099061448@sss.pgh.pa.us
Whole thread Raw
In response to tablespaces for temporary files  (Neil Conway <neilc@samurai.com>)
Responses Re: tablespaces for temporary files
Re: tablespaces for temporary files
List pgsql-hackers
Neil Conway <neilc@samurai.com> writes:
> So I'd like to add a GUC variable called something like
> "scratch_tablespace". If undefined (the default), temporary files for
> sorting/etc. will be created in the current database's tablespace.

(1) What are the protection requirements for this variable?

(2) I don't think that "undefined" is a particularly good concept for
GUC variables.  Particularly not ones that you are envisioning setting
from multiple places.

(3) I don't like the idea that a catalog lookup will be necessary before
we can create or access temp files.  It would be quite unacceptable from
a modularity standpoint to have the low-level routines that currently
determine temp file paths do catalog accesses.

On the whole I'm unconvinced that this is worth the trouble.  One of the
reasons for allowing people to move databases around is to determine
where their temp files go.  Also, it's always been possible for people
to change the pgsql_tmp subdirectory into a symlink.  While I know that
that isn't particularly DBA-friendly, it seems sufficient to me for what
I suspect is a third-order requirement.

Let's at least wait till we get some demand from the field before we
start inventing frammishes for tablespaces.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Unixware 714 pthreads
Next
From: Bruce Momjian
Date:
Subject: Re: [pgsql-hackers-win32] Win32 open items