Re: Detach/attach database

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Thom Brown <thom(at)linux(dot)com>
Cc: PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Detach/attach database
Date: 2011-11-13 15:26:32
Message-ID: CA+U5nMJt=ndva-Rx5u8SjJhZfmX_qwhtfChDB34K1005t6aO_Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, Nov 13, 2011 at 1:13 PM, Thom Brown <thom(at)linux(dot)com> wrote:

> I don't know if this has been discussed before, but would it be
> feasible to introduce the ability to detach and attach databases? (if
> you're thinking "stop right there" skip to the end)  What I had in
> mind would be to do something like the following:

That would be better done at the tablespace level, and then the
feature becomes "transportable tablespaces". Which seems like a good
and useful idea to me.

> You may now be able to infer where this notion came from, when someone
> asked if you can clone databases without kicking users off.  However,
> this isn't a schema-only copy, but naturally contains data as well.

The OP wanted to do this without freezing activity on the database,
which is not easy...

OTOH we can do a backup of just a single database and then filter
recovery at database level to produce just a single copy of another
database on its own server, if anyone wanted that.

--
 Simon Riggs                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2011-11-13 15:57:35 Re: Detach/attach database
Previous Message Thom Brown 2011-11-13 13:13:11 Detach/attach database