]> git.sur5r.net Git - bacula/docs/blobdiff - docs/manual/sqlite.tex
Fix remaining autochanger command for full output
[bacula/docs] / docs / manual / sqlite.tex
index d94a5683065d2eddcd539601fe981cbf525c436d..2c52a5266bb6a73555ee164ed4efdabb9044da39 100644 (file)
@@ -19,6 +19,14 @@ location (for the moment) for SQLite is in the dependency package {\bf
 depkgs/sqlite-2.8.16}. Please note that the version will be updated as new
 versions are available and tested. 
 
+You may install and use SQLite version 3.x with Bacula by using:
+{\bf ./configure \verb:--:with-sqlite3}. You should ensure that
+when the database is created that you have used 
+\begin{verbatim}
+PRAGMA synchronous = NORMAL;
+\end{verbatim}
+otherwiset SQLite version 3.x is 4 to 10 times slower than version 2.8.16.
+
 Installing and Configuring is quite easy. 
 
 \begin{enumerate}
@@ -27,18 +35,18 @@ Installing and Configuring is quite easy.
 
    {\bf tar xvfz depkgs.tar.gz}  
 
-Note, the above command requires GNU tar. If you do not  have GNU tar, a
-command such as:
+   Note, the above command requires GNU tar. If you do not  have GNU tar, a
+   command such as:
 
-{\bf zcat depkgs.tar.gz | tar xvf -}
+   {\bf zcat depkgs.tar.gz | tar xvf -}
 
-will probably accomplish the same thing. 
+   will probably accomplish the same thing. 
 
 \item {\bf cd depkgs}
 
 \item {\bf make sqlite}  
 
-   \end{enumerate}
+\end{enumerate}
 
 At this point, you should return to completing the installation of {\bf
 Bacula}. 
@@ -75,9 +83,9 @@ At this point, you can create the SQLite database and tables:
 \item ./make\_sqlite\_tables
 
    This script creates the SQLite database as well as the  tables used by {\bf
-Bacula}. This script will be  automatically setup by the {\bf ./configure}
-program  to create a database named {\bf bacula.db} in {\bf Bacula's}  working
-directory. 
+   Bacula}. This script will be  automatically setup by the {\bf ./configure}
+   program  to create a database named {\bf bacula.db} in {\bf Bacula's}  working
+   directory. 
 \end{enumerate}
 
 \subsection*{Linking Bacula with SQLite}
@@ -93,9 +101,30 @@ the SQLite libraries will be linked into {\bf Bacula}.
 \index[general]{Testing SQLite }
 \addcontentsline{toc}{subsection}{Testing SQLite}
 
-As of this date (20 March 2002), we have much less ``production'' experience
-using SQLite than using MySQL. That said, we should note that SQLite has
-performed flawlessly for us in all our testing. 
+We have much less "production" experience
+using SQLite than using MySQL. SQLite has
+performed flawlessly for us in all our testing. However,
+several users have reported corrupted databases while using
+SQLite. For that reason, we do not recommend it for production
+use.
+
+If Bacula crashes with the following type of error when it is started:
+\footnotesize
+\begin{verbatim}
+Using default Catalog name=MyCatalog DB=bacula
+Could not open database "bacula".
+sqlite.c:151 Unable to open Database=/var/lib/bacula/bacula.db.
+ERR=malformed database schema - unable to open a temporary database file
+for storing temporary tables
+\end{verbatim}
+\normalsize
+
+this is most likely caused by the fact that some versions of
+SQLite attempt to create a temporary file in the current directory.
+If that fails, because Bacula does not have write permission on
+the current directory, then you may get this errr.  The solution is
+to start Bacula in a current directory where it has write permission.
+
 
 \subsection*{Re-initializing the Catalog Database}
 \index[general]{Database!Re-initializing the Catalog }