From: | rihad <rihad(at)mail(dot)ru> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | Are pg_xlog/* fiels necessary for PITR? |
Date: | 2011-10-27 14:27:30 |
Message-ID: | 4EA96A52.7080909@mail.ru |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Hi, I'm backing up the entire server directory from time to time.
pg_xlog/ directory containing WAL files is pretty heavy
(wal_level=archive). Can I exclude it from the regular tar archive?
#!/bin/sh
renice 20 $$ 2>/dev/null
pgsql -U pgsql -q -c "CHECKPOINT" postgres # speed up pg_start_backup()
pgsql -U pgsql -q -c "select pg_start_backup('sol')" postgres
tar -cjf - /db 2>/dev/null | ssh -q -i ~pgsql/.ssh/id_rsa -p 2022 -c
blowfish dbarchive(at)10(dot)0(dot)0(dot)1 'cat > db.tbz'
pgsql -U pgsql -q -c "select pg_stop_backup()" postgres
sleep 60 #wait for new WAL backups to appear
echo 'ssh -q dbarchive(at)10(dot)0(dot)0(dot)1 ./post-backup.sh' | su -m pgsql
I want to change tar invocation to be: tar -cjf --exclude 'db/pg_xlog/*' ...
Will there be enough data in case of recovery? (May God forbid... )))
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2011-10-27 14:44:34 | Re: WAL file size vs. data file size |
Previous Message | Ing.Edmundo.Robles.Lopez | 2011-10-27 14:00:05 | Getting X coordinate from a point(lseg), btw i read the man page about points. |