From: | Jaime Casanova <jcasanov(at)systemguards(dot)com(dot)ec> |
---|---|
To: | Fujii Masao <masao(dot)fujii(at)gmail(dot)com> |
Cc: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Creating a tablespace directory in recovery |
Date: | 2009-04-30 20:57:52 |
Message-ID: | 3073cc9b0904301357s4f5c1at9d51ad9ebca9e270@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, Apr 30, 2009 at 3:50 PM, Jaime Casanova
<jcasanov(at)systemguards(dot)com(dot)ec> wrote:
> On Thu, Apr 30, 2009 at 2:58 AM, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>> Hi,
>>
>> Does anyone know why a tablespace directory isn't automatically
>> created in recovery? I think that it's troublesome to create all the
>> directories before recovery.
>>
>
> i guess it's because you need an absolute path to create tablespaces
> and the appropiate path could not exist in the other machine (assuming
> you are using recovery for warm standby or because you are recreating
> a database after reinstall your server).
>
From the caveats section in
http://www.postgresql.org/docs/8.3/static/continuous-archiving.html#BACKUP-PITR-RECOVERY:
"""
* CREATE TABLESPACE commands are WAL-logged with the literal
absolute path, and will therefore be replayed as tablespace creations
with the same absolute path. This might be undesirable if the log is
being replayed on a different machine. It can be dangerous even if the
log is being replayed on the same machine, but into a new data
directory: the replay will still overwrite the contents of the
original tablespace. To avoid potential gotchas of this sort, the best
practice is to take a new base backup after creating or dropping
tablespaces.
"""
--
Atentamente,
Jaime Casanova
Soporte y capacitación de PostgreSQL
Asesoría y desarrollo de sistemas
Guayaquil - Ecuador
Cel. +59387171157
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2009-04-30 21:10:06 | plpgsql's EXIT versus block and loop nesting |
Previous Message | Jaime Casanova | 2009-04-30 20:50:09 | Re: Creating a tablespace directory in recovery |