Re: tablespace and sequences?

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Stefan Kaltenbrunner <stefan(at)kaltenbrunner(dot)cc>, PostgreSQL Developers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: tablespace and sequences?
Date: 2004-08-18 07:30:13
Message-ID: Pine.LNX.4.58.0408180903000.30419@sablons.cri.ensmp.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-cygwin pgsql-hackers pgsql-hackers-win32


Dear Christopher,

> > Allow database recovery where tablespaces can't be created
>
> How is that at all a problem?

It is enough a small problem to be put in the todo list.

> It's no different to the requirement to have installed all your contrib
> .so's before running your restore, what's so hard about making a few
> dirs? It's also no different to the old database locations support.
> Personally, I think it's a non-issue.

Well, maybe.

I think the .so comparison is not fully appropriate, as the installation
is quite generic an issue, possibly addressed by packaging or some
scripting.

As for pg_dump/pg_restore, they are performed at the database level.
In the previous situation with "LOCATION", one had to handle the issue of
creating the database before a restoration.

Now with tablespace the issue is more specific, and it is possibly
embedded at the SQL level output by pg_dump/pg_restore, on which one has
much less control.

Well, maybe you suggest I can do some "| sed 's/TABLESPACE \w+//g' |" as a
kludge somewhere, or create dummy tablespaces even if I have only one
disk. That does not look really good, and I won't know what is needed by
looking at a pg_dump compressed generated file.

Maybe the right answer is that disks are now large and cheap, so who will
need tablespace anyway? So indeed there is no problem;-)

> It's also impossible to do as you suggest and have a --ignore-tablespace
> flag.

I was not arguing about implementation, but about a desirable feature for
a basic database admin.

Anyway, I think it could be implemented, possibly with some twicking in
the format, or with some setting on the server side.

Now I agree that any other feature which provide the ability to handle
this "non" issue would be welcome, I won't stick on this particular
option.

> All it could do is at dump time to dump NO tablespace, which is
> NOT what you want.

Wow! you know what I may want although I even don't know;-)

If I want to move a database from one server to another, I'm not sure the
disk layout and tablespace issues will have been handled the same way on
both machines. So some help to handle these issues would be welcome.

> At restore time it doesn't do anything since pg_dumpall is a text format
> only.

I'm not thinking about pg_dumpall but pg_dump/pg_restore.

Have a nice day,

--
Fabien Coelho - coelho(at)cri(dot)ensmp(dot)fr

In response to

Responses

Browse pgsql-cygwin by date

  From Date Subject
Next Message Christopher Kings-Lynne 2004-08-18 07:45:41 Re: tablespace and sequences?
Previous Message Christopher Kings-Lynne 2004-08-18 01:33:53 Re: tablespace and sequences?

Browse pgsql-hackers by date

  From Date Subject
Next Message Christopher Kings-Lynne 2004-08-18 07:45:41 Re: tablespace and sequences?
Previous Message Honza Pazdziora 2004-08-18 06:55:36 Re: Does psql use nested transactions?

Browse pgsql-hackers-win32 by date

  From Date Subject
Next Message Christopher Kings-Lynne 2004-08-18 07:45:41 Re: tablespace and sequences?
Previous Message Dave Page 2004-08-18 07:29:08 Re: [PATCHES] Win32 Event log