0I&Berkeley DB: db_archive[P

db_archive





*db_archive [-alsv] [-h home]




Description



AThe db_archive utility writes the pathnames of log files that areCno longer in use (e.g., no longer involved in active transactions),.to the standard output, one pathname per line.IThese log files should be written to backup media to provide for recoveryJin the case of catastrophic failure (which also requires a snapshot of thedatabase files),Cbut they may then be deleted from the system to reclaim disk space.

The options are as follows:

>

-a
Write all pathnames as absolute pathnames,5instead of relative to the database home directories.>

-h
Specify a home directory for the database.M

-l
Write out the pathnames of all of the database log files,8whether or not they are involved in active transactions.]

-s
Write the pathnames of all of the database files that need to be archived;in order to recover the database from catastrophic failure.JIf any of the database files have not been accessed during the lifetime of&the current log files, db_archive willnot include them in thisoutput.

FIt is possible that some of the files referenced in the log have sincebeen deleted from the system.*In this case, db_archive will ignore them.eWhen db_recover is run, any files referenced in the log thatIare not present during recovery are assumed to have been deleted and willnot be recovered.Y

-v
Run in verbose mode, listing the checkpoints in the log files as they are reviewed.


OThe db_archive utility attaches to one or more of the Berkeley DB shared memoryHregions. In order to avoid region corruption, it should always be givenJthe chance to detach and exit gracefully. To cause db_archive to clean up<after itself and exit, send it an interrupt signal (SIGINT).

}The log_archive function is the underlying function used by the db_archive utility.tSee the db_archive utility source code for an example of using log_archivein a POSIX 1003.1 environment.

EThe db_archive utility exits 0 on success, and >0 if an error occurs.



Environment Variables





DB_HOME
EIf the -h option is not specified and the environment variableIDB_HOME is set, it is used as the path of the database home, as described8in db_appinit.




See Also

db_archive,:db_checkpoint,6db_deadlock,.db_dump,.db_load,4db_recover,and.db_stat.
ÿÿ