[Zope] Re: Packing Data.fs

Philipp von Weitershausen philipp at weitershausen.de
Wed Aug 30 08:51:41 EDT 2006


Duncan Booth wrote:
> Tres Seaver wrote:
> 
>> Mark Gibson wrote:
>>> I know zope makes a copy of Data.fs before packing.  Is it possible to
>>> specify a location other than <zope>/var to place that copy?
>> Actually, it makes a *new* file when packing, and then unlinks the old
>> file and re-links the copy under its name after finishing the pack
>> successfully.  If you are looking to "spread the love" across multiple
>> partitions, you can symlink the original file into a directory on
>> another drive / partition, and then do the pack there.  One the pack
>> completes, you can move or copy the packed version back to the original
>> directory.
>>
> I recently had to move a fairly large Data.fs onto a different partition, 
> but just copying it would have involved downtime (at least for 
> authoring) that I wanted to avoid. 
> 
> The solution I came up with was to create a var folder on the new partition 
> symlinking back to Data.fs in the original location. Then I switched ZEO to 
> using the var on the new partition and packed the database. After packing 
> the database was on the new partition with no downtime apart from a single 
> ZEO restart.

Nice.

I should note that DirectoryStorage (http://dirstorage.sf.net) has
excellent replication support which make things like moving live Zope
instances from one partition to another one w/o lots of downtime almost
trivial.

Philipp



More information about the Zope mailing list