pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Boris Bukowski <bukowski@louis.info>
To: pgsql-admin@postgresql.org
Subject: Base Backups to a remote location
Date: Fri, 6 Dec 2013 11:05:53 +0100
Message-ID: <MP75BCF26F00D12852A1A181.6040300@louis.info> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-admin>

Hi,

i use the following script to backup servers every day to a remote location.

---snip---
REMOTE=xyz123.louis.info
DATE=`date +%Y%m%d%H%M%S`

ssh xyz123.louis.info "echo \"checkpoint; SELECT 
pg_start_backup('${DATE}');\" |psql"

rsync -avxz  --numeric-ids --exclude-from=/backup1/config/excludes.txt 
--delete-excluded --inplace --delete root@${REMOTE}:/ 
/mnt/backup1/remote/xyz123/full

ssh xyz123.louis.info "echo \"SELECT pg_stop_backup();\" |psql"

---snip---

i have some questions about this:
1. will this always work?
2. between these backups i do not save the archive logs, is this secure?
3. is it save to empty the archive directory befor i do a backup with 
pg_start_backup()?

best Regards
Boris Bukowski



-- 
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin



view thread (6+ messages)  latest in thread

Message-ID: <MP75BCF26F00D12852A1A181.6040300@louis.info>
Permalink:  ../MP75BCF26F00D12852A1A181.6040300@louis.info/
Also on:    postgresql.org/message-id/MP75BCF26F00D12852A1A181.6040300@louis.info

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: bukowski@louis.info
  Subject: Re: Base Backups to a remote location
  In-Reply-To: <MP75BCF26F00D12852A1A181.6040300@louis.info>
  References: <MP75BCF26F00D12852A1A181.6040300@louis.info>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox