Re: virtualized snapshots and PITR

From: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>
To: Achilleas Mantzios <achill(at)matrix(dot)gatewaynet(dot)com>, pgsql-admin(at)lists(dot)postgresql(dot)org
Subject: Re: virtualized snapshots and PITR
Date: 2017-12-14 09:30:10
Message-ID: 1513243810.5112.8.camel@cybertec.at
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Achilleas Mantzios wrote:
> > > Anyone know of a way to do PITR recoveries with veeam?
> >
> > It is fairly simple.
> >
> > Before the snapshot, run
> >
> > SELECT pg_start_backup('label of your choice', TRUE);
> >
> > After the snapshot, run
> >
> > SELECT pg_stop_backup();
>
> This will create the data/backup_label file necessary for a minimal consistent recover,
> but wouldn't he also have a recovery.conf in place, so that the server will keep
> reading wals till it reaches the recovery target?

Yes, for point-in-time recovery you would need a recovery.conf file
with at least a "restore_command" in it.

> And if the system comes up live he won't have the chance to create this directory.

That's an interesting point; I didn't think of it.

One thing I can think of is to disable PostgreSQL autostart
while you take the snapshot.

> Basically what we do ourselves is exactly what you suggest.
> I'll have to ask if state (mem/cpu/registers/etc) is restored as well.

Such a kind of snapshot wouldn't be useful for a database backup.
You only want the storage.

Yours,
Laurenz Albe

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message PropAAS DBA 2017-12-14 15:29:04 Re: virtualized snapshots and PITR
Previous Message Achilleas Mantzios 2017-12-14 09:02:37 Re: virtualized snapshots and PITR