Re: UFS2 Snapshots and Postgres

From: Karl Denninger <karl(at)denninger(dot)net>
To: Eduardo Morras <nec556(at)retena(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: UFS2 Snapshots and Postgres
Date: 2012-06-25 13:16:53
Message-ID: 4FE864C5.8020007@denninger.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 6/25/2012 7:35 AM, Eduardo Morras wrote:
>
> Hi everyone,
>
> I'm using FreeBSD 9 for Postgres and want to know if these actions are
> safe for make a backup of the database:
>
> a) call pg_start_backup('b1')
> b) take an UFS2 snapshot of data files
> c) call pg_stop_backup()
> d) change to the snapshot dir and rsync/dd/dump/transfer it to backup
> file server
>
> Is it safe to call pg_start_backup('b1',true)?
>
> Thanks in advance
>
Snapshots are "safe" (but will result in a roll-forward on restart) IF
AND ONLY IF the log data and database table spaces are all on the same
snapshotted volume.

IF THEY ARE NOT then it will probably work 95% of the time, and the
other 5% it will be unrecoverable. Be very, very careful -- the
snapshot must in fact snapshot ALL of the involved database volumes (log
data included!) at the same instant.

--
Karl Denninger
karl(at)denninger(dot)net
/The Market Ticker/

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Alban Hertroys 2012-06-25 13:27:38 Re: Help, server doesn't start
Previous Message Craig Ringer 2012-06-25 12:43:37 Re: Help, server doesn't start