[Zope] Backup while zope's running
Toby Dickenson
tdickenson@geminidataloggers.com
Mon, 16 Jun 2003 10:05:53 +0100
On Monday 16 June 2003 09:40, Chris Withers wrote:
> FNk wrote:
> > Is there a way to perform a backup of Data.fs (and the zope instance for
> > that matter?) while zope is running and users are logged on (reading and
> > uploading files)?
>
> Yeah, cp the Data.fs. It's a sequential transaction log so it's fine to be
> copied while still in use.
That is almost certainly true.
I supect it may be possible for a zope user with the 'undo' permission to
intentionally break this using a "non-transactional undo". The normal undo
gui in zope uses transactional undo, so there is no way that this can happen
accidentally.
> > Is it possible to perform an incremental backup?
>
> Yup, ask Toby Dickenson, the master of these sorts of things. He'll
> probably recommend DirectoryStorage, but may be able to help with
> FileStorage too...
If you want to stick with FileStorage I recommend your backup script starts
with "cp Data.fs Data.fs.to.be.backed.up". Then, its up to you to figure out
how to take an incremental backup of Data.fs.to.be.backed.up
Dont back up the Data.fs directly unless you are very sure that your backup
system reads the file in one pass from start to end. rsync is one notable
example that does not.
You may want to look at other options if you cant afford the IO costs of that
"cp" pass (if your storage is huge, or your backups frequent). Both
DirectoryStorage and BDBStorage handle incremental backups in some form.
--
Toby Dickenson
http://www.geminidataloggers.com/people/tdickenson