Thread: copy a barman snapshot to another backup server

copy a barman snapshot to another backup server

From
Willy-Bas Loos
Date:
Hi,

We use barman for backups.
We have an on-site backup server that sits in the same rack as the other servers, which holds a month worth of backups.

We also have an off-site backup server in another city that always holds 1 backup snapshot of all servers, to protect the data in case of a fire or natural disaster. But i haven't included the barman backups in that yet.

What would be the best way to pull a snapshot from barman?

The snapshots are pulled by the off-site server using rsync; we have no access from on-site to off-site. So what I'd do is restore a backup locally on the on-site backup server and backup that from off-site.
That would be wasting some space and IO though, a snapshot is about 1TB. Is there a more efficient way? E.g, i was hoping to somehow hardlink the local restore, but i haven't found a way yet.

Cheers,

--
Willy-Bas Loos

Re: copy a barman snapshot to another backup server

From
Willy-Bas Loos
Date:
AFAIK the directory structure of the base backups is the same as a running server, only the pg_xlog directory is empty.
So, maybe it would be possible to hardlink that, except the pg_xlog, and then restore the WAL in a "real" pg_xlog fiolder with "barman get-wal ..."
And then i could backup that to the off-site server.

Only, how do i know which WAL-id's to restore?



--
Willy-Bas Loos

Re: copy a barman snapshot to another backup server

From
Willy-Bas Loos
Date:
On Tue, Dec 1, 2015 at 6:05 PM, Willy-Bas Loos <willybas@gmail.com> wrote:
Only, how do i know which WAL-id's to restore?

Aha, it turns out that i overlooked the command list-files. It can list all the files in the backup, or just the WAL files (and more options).
A big thanks to Giulio Calacoci of 2ndQuadrant .

Cheers,

--
Willy-Bas Loos