Database Maintenance

Top  Previous  Next

Options and Configuration > Tools Menu > Database Maintenance

From time to time, you may need to perform some database maintenance.  There are some checks made at startup to detect and correct database corruption (the sort that can occur in any database if the power gets cut at just the wrong time, or if Windows crashes during a buffer write).  And as clips are deleted from the trash, the space is automatically re-used by new clips.

But you may wish to occasionally perform a thorough database check and compaction.  We now have two options - the one that is built into the database engine, and one that we've recently built ourselves.

Comprehensive Database Repair

This is our new database repair function, technically known as a "database reorganization".  This routine actually creates a new database (in the same directory), and copies all of your (valid) data into it.  It will take several minutes to run, especially on large databases.  If you find that you have database-related errors, or notice that your database directory or backup files are unexplainably large (ex: 100MB when you only have 100 clips), then run this function to clear it up.  You'll find it under File | Database Maintenance | Comprehensive Database Repair.  A database backup is automatically initiated at the beginning of the process, to avoid data loss should problems arise during this lengthy operation (such as a loss of power).

This routine will also empty the trash, and takes care of any database fragmentation issues.

Verify/Repair/Compact Database (simple repair)

This is the repair function built into the database.  We're leaving it in "just in case" we run into situations where our new routine can't deal with a particular situation.

Run Cleanup Now

This causes the purging and aging process to run right now, moving old clips from collections that have reached their "retention limit", into the Overflow. Then it purges the Overflow collection into the trash, if it has also reached its own retention limit.  You may need to reload any given collection (including Overflow) to see its actual contents.

The cleanup usually runs at startup, shutdown, or it may do a little bit during long periods of idle time.  Occasionally, this can cause slowdowns or delays in startup/shutdown, so you can turn off the automatic cleanup, and just do it manually as required.

See Database Properties to see how your automatic database cleanup is configured.

Backup Files

As you run the database maintenance, a set of backup files may be created in the database directory.  Each file in the data directory ending in a "K" is the backup.  For example, BLOBTXT.BLB gets backed up to BLOBTXT.BBK.  These files will be automatically deleted after two days.

Note that these do NOT mean that you no longer need to make regular backups of your data.  This is just a safeguard in case the database maintenance is interrupted, or has some sort of unforeseen problem.

Exclusivity

Database maintenance requires exclusive access to the database files  If you are in a multi-user environment, sharing a common database, then you need to have all other users close ClipMate (or de-activate the shared database).  ClipMate will let you know if it attempts to perform database maintenance and cannot continue.