\item[Solution]
For SQLite, use the vacuum command to try to fix the database. For either
MySQL or PostgreSQL, see the vendor's documentation. They have specific tools
- that check and repair databases.
+ that check and repair databases, see the \ilink{database
+ repair}{DatabaseRepair} sections of this manual for links to vendor
+ information.
Assuming the above does not resolve the problem, you will need to restore
- or rebuild your catalog.
+ or rebuild your catalog. Note, if it is a matter of some
+ inconsistencies in the Bacula tables rather than a broken database, then
+ running \ilink{dbcheck}{dbcheck} might help, but you will need to ensure
+ that your database indexes are properly setup. Please see
+ the \ilink{Database Performance Issues}{DatabasePerformance} sections
+ of this manual for more details.
+
\item[Problem]
How do I restore my catalog?
-\item[Solution]
+\item[Solution with a Catalog backup]
If you have backed up your database nightly (as you should) and you
have made a bootstrap file, you can immediately load back your
database (or the ASCII SQL output). Make a copy of your current
you will probably erase your newly restored database tables.
-\item[Solution]
+\item[Solution with a Job listing]
If you did save your database but did not make a bootstrap file, then
recovering the database is more difficult. You will probably need to
use bextract to extract the backup copy. First you should locate the
backup, you do NOT want to do a {\bf make_bacula_tables} command, or
you will probably erase your newly restored database tables.
+\item [Solution withou a Job Listing]
+ If you do not have a job listing, then it is a bit more difficult.
+ Either you use the \ilink{bscan}{bscan} program to scan the contents
+ of your tape into a database, which can be very time consuming
+ depending on the size of the tape, or you can use the \ilink{bls}{bls}
+ program to list everything on the tape, and reconstruct a bootstrap
+ file from the bls listing for the file or files you want following
+ the instructions given above.
+
+ There is a specific example of how to use {\bf bls} below.
\item [Problem]
I try to restore the last known good full backup by specifying
know the Volume to which it was backed up.
\item [Solution]
- Use {\bf bls} to indicate where it is on the tape. For example:
+ Either bscan the tape, or use {\bf bls} to indicate where it is on the
+ tape. For example:
\footnotesize
\begin{verbatim}