Re: Differential Backups - Mailing list pgsql-general

From hubert depesz lubaczewski
Subject Re: Differential Backups
Date
Msg-id 20011031065125.7a9c7929.depesz@depesz.pl
Whole thread Raw
In response to Re: Differential Backups  ("Jeff Lu" <jklcom@mindspring.com>)
List pgsql-general
On Tue, 30 Oct 2001 11:05:48 -0800
"Jeff Lu" <jklcom@mindspring.com> wrote:

> Can you show me an example on doing a backup using xdelta?

sure.
what i will show assumes that usually you want newest backup to be available
fastest. older backups can take some time to generate.

first make your standard pg_dump to some file. let's call it dump.sql
$ pg_dump -d dump.sql .........
o.k.
now next day (and every following day too) you do:
$ pg_dump -d new.dump ........
$ xdelta delta new.dump dump.sql patch_file_name
$ mv -f new.dump dump.sql

now in dump.sql you always have the newest dump file, while patch file
contains information how to get older patch from newer.
how to patch?

$ xdelta patch patch_file_name dump.sql old.dump.sql

all you have to do is to store these patchfiles forever, or just ocassionally
(once in a month) make full backup instead of differential.

depesz

--
hubert depesz lubaczewski                          http://www.depesz.pl/
------------------------------------------------------------------------
... vows are spoken to be broken ...                 [enjoy the silence]
... words are meaningless and forgettable ...             [depeche mode]

pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: Database corruption?
Next
From: tony
Date:
Subject: function gurus...