Library Version 18.1.40

Supporting utilities
Prev | Chapter 8. Berkeley DB Architecture | Next

## Supporting utilities

The following are the standalone utilities that provide supporting functionality for the Berkeley DB environment:

db_archive utility
  The db_archive utility supports database backup and archival, and log file administration. It facilitates log reclamation and the creation of database snapshots. Generally, some form of log archival must be done if a database environment has been configured for logging or transactions.
db_checkpoint utility
  The db_checkpoint utility runs as a daemon process, monitoring the database log and periodically issuing checkpoints. It facilitates log reclamation and the creation of database snapshots. Generally, some form of database checkpointing must be done if a database environment has been configured for transactions.
db_deadlock utility
  The db_deadlock utility runs as a daemon process, periodically traversing the database lock structures and aborting transactions when it detects a deadlock. Generally, some form of deadlock detection must be done if a database environment has been configured for locking.
db_dump utility
  The db_dump utility writes a copy of the database to a flat-text file in a portable format.
db_hotbackup utility
  The db_hotbackup utility creates "hot backup" or "hot failover" snapshots of Berkeley DB database environments.
db_load utility
  The db_load utility reads the flat-text file produced by the db_load utility and loads it into a database file.
db_printlog utility
  The db_printlog utility displays the contents of Berkeley DB log files in a human-readable and parsable format.
db_recover utility
  The db_recover utility runs after an unexpected Berkeley DB or system failure to restore the database to a consistent state. Generally, some form of database recovery must be done if databases are being modified.
db_stat utility
  The db_stat utility displays statistics for databases and database environments.
db_tuner utility
  The db_tuner utility suggests a page size for btree databases that optimizes cache efficiency and storage space requirements.
db_upgrade utility
  The db_upgrade utility provides a command-line interface for upgrading underlying database formats.
db_verify utility
  The db_verify utility provides a command-line interface for verifying the database format.

All of the functionality implemented for these utilities is also available as part of the standard Berkeley DB API. This means that threaded applications can easily create a thread that calls the same Berkeley DB functions as do the utilities. This often simplifies an application environment by removing the necessity for multiple processes to negotiate database and database environment creation and shut down.

Prev | Up | Next
Scripting languages | Home | Chapter 9. The Berkeley DB Environment