[ZODB-Dev] Remember date of last pack?

Jim Fulton jim at zope.com
Mon Jul 26 11:36:37 EDT 2010


On Mon, Jul 26, 2010 at 11:14 AM, Christian Zagrodnick <cz at gocept.com> wrote:
> Hi,
>
> for monitoring if a storage has been packed it would be handy if it
> remembered the date of its last pack. An easy solution for file storage
> would be to create a Data.fs.packed file.
>
> Other ways do determine the date would be:
>
> - Use age of Data.fs.old: very implicit; file is not available during
> packing (thus monitoring becomes difficult); it is not required to keep
> Data.fs.old
> - Provide a wrapper script around zeopack which stores the information:
> while that would work it is rather tedious to provide that again and
> again for each buildout/installation.
>
> Comments?

ZEO servers log when databases are packed.  I often look at the ZEO
logs to verify that databases have been packed.

File-storage packed database records have a status flag of "p", so you
can determine the approximate (depending on how active your database
is) date of last pack by scanning the transaction headers.

Jim

-- 
Jim Fulton


More information about the ZODB-Dev mailing list