From d461e446098eb2723f526c06882fad63aa7ed634 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Beno=C3=AEt=20S=C3=89RIE?= Date: Tue, 4 Apr 2017 09:47:47 +0200 Subject: [PATCH] Another method with gzip directly piped for pg_dumpall. --- docs/zzz_evobackup | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/zzz_evobackup b/docs/zzz_evobackup index 099beae..3706aaf 100755 --- a/docs/zzz_evobackup +++ b/docs/zzz_evobackup @@ -97,6 +97,10 @@ mkdir -p -m 700 /home/backup ## example with pg_dumpall (warning: you need space in ~postgres) # su - postgres -c "pg_dumpall > ~/pg.dump.bak" # mv ~postgres/pg.dump.bak /home/backup/ +## another method with gzip directly piped +# cd /var/lib/postgresql +# sudo -u postgres pg_dumpall | gzip > /home/backup/pg.dump.bak.gz +# cd - ## example with all tables from MYBASE excepts TABLE1 and TABLE2 # pg_dump -p 5432 -h 127.0.0.1 -U USER --clean -F t --inserts -f /home/backup/pg-backup.tar -t 'TABLE1' -t 'TABLE2' MYBASE