%%
\chapter{Autochanger Resource}
-\label{Autochangerres}
\index[sd]{Autochanger Resource}
\index[sd]{Resource!Autochanger}
\begin{description}
\item [Name = \lt{}Autochanger-Name\gt{}]
\index[sd]{Name}
- Specifies the Name of the Autochanger. This name is used in
- the Director's Storage definition to refer to the autochanger.
- This directive is required.
+ Specifies the Name of the Autochanger. This name is used in the
+ Director's Storage definition to refer to the autochanger. This
+ directive is required.
\item [Device = \lt{}Device-name1, device-name2, ...\gt{}]
- Specifies the names of the Device resource or
- resources that correspond
- to the autochanger drive. If you have a multiple drive
- autochanger, you must specify multiple Device names, each
- one referring to a separate Device resource that contains a
- Drive Index specification that corresponds to the drive
- number base zero. You may specify multiple device names on
- a single line separated by commas, and/or you may specify
- multiple Device directives.
- This directive is required.
+ Specifies the names of the Device resource or resources that correspond
+ to the autochanger drive. If you have a multiple drive autochanger, you
+ must specify multiple Device names, each one referring to a separate
+ Device resource that contains a Drive Index specification that
+ corresponds to the drive number base zero. You may specify multiple
+ device names on a single line separated by commas, and/or you may
+ specify multiple Device directives. This directive is required.
\item [Changer Device = {\it name-string}]
\index[sd]{Changer Device}
if {\bf /dev/sg0} is incorrect. For example, on FreeBSD systems, the
autochanger SCSI control device is generally {\bf /dev/pass2}.
-\item [/etc/bacula/mtx-changer \ /dev/sg0 \ slots \ 0 \ /dev/nst0 \ 0]
+\item [/etc/bacula/mtx-changer \ /dev/sg0 \ slots ]
\index[sd]{mtx-changer slots}
This command should return the number of slots in your autochanger.
-\item [/etc/bacula/mtx-changer \ /dev/sg0 \ unload \ ]
+\item [/etc/bacula/mtx-changer \ /dev/sg0 \ unload \ 1 \ /dev/nst0 \ 0 ]
\index[sd]{mtx-changer unload}
- If a tape is loaded, this should cause it to be unloaded.
+ If a tape is loaded from slot 1, this should cause it to be unloaded.
\item [/etc/bacula/mtx-changer \ /dev/sg0 \ load \ 3 \ /dev/nst0 \ 0 ]
\index[sd]{mtx-changer load}
-Assuming you have a tape in slot 3, it will be loaded into the read slot (0).
+Assuming you have a tape in slot 3, it will be loaded into drive (0).
\item [/etc/bacula/mtx-changer \ /dev/sg0 \ loaded \ 0 \ /dev/nst0 \ 0]
\index[sd]{mtx-changer loaded}
It should print "3"
+Note, we have used an "illegal" slot number 0. In this case, it is simply
+ignored because the slot number is not used. However, it must be specified
+because the drive parameter at the end of the command is needed to select
+the correct drive.
+
+\item [/etc/bacula/mtx-changer \ /dev/sg0 \ unload \ 3 /dev/nst0 \ 0]
+
+will unload the tape into slot 3.
-\item [/etc/bacula/mtx-changer \ /dev/sg0 \ unload]
\end{description}
Once all the above commands work correctly, assuming that you have the right
\footnotesize
\begin{verbatim}
#!/bin/sh
-/etc/bacula/mtx-changer /dev/sg0 unload
-/etc/bacula/mtx-changer /dev/sg0 load 3
+/etc/bacula/mtx-changer /dev/sg0 unload 1 /dev/nst0 0
+/etc/bacula/mtx-changer /dev/sg0 load 3 /dev/nst0 0
mt -f /dev/st0 rewind
mt -f /dev/st0 weof
\end{verbatim}
\footnotesize
\begin{verbatim}
#!/bin/sh
-/etc/bacula/mtx-changer /dev/sg0 unload
+/etc/bacula/mtx-changer /dev/sg0 unload 1 /dev/nst0 0
mt -f /dev/st0 offline
-/etc/bacula/mtx-changer /dev/sg0 load 3
+/etc/bacula/mtx-changer /dev/sg0 load 3 /dev/nst0 0
mt -f /dev/st0 rewind
mt -f /dev/st0 weof
\end{verbatim}
are reached, the data will be despooled and written to tape. When this
directive is set to yes, the Spool Attributes is also automatically set to
yes. Spooling data prevents tape shoe-shine (start and stop) during
- Incremental saves. This option should not be used if you are writing to a
- disk file.
+ Incremental saves. If you are writing to a disk file using this option
+ will probably just slow down the backup jobs.
\item [Spool Attributes = \lt{}yes|no\gt{}]
\index[dir]{Spool Attributes}
\item [WritePartAfterJob=yes|no]
\index[dir]{WritePartAfterJob}
\index[dir]{Directive!WritePartAfterJob}
- tells Bacula to request the Storage daemon to write the current part file to
- the device when the job is finished (see
- \ilink{Write Part After Job directive in the Job
- resource}{WritePartAfterJob}). Please note, this directive is implemented
- only in version 1.37 and later. The default is yes. We strongly
- recommend that you keep this set to yes otherwise, when the last job
- has finished one part will remain in the spool file and restore may
- or may not work.
+ tells Bacula to request the Storage daemon to write the current part
+ file to the device when the job is finished (see \ilink{Write Part After
+ Job directive in the Job resource}{WritePartAfterJob}). Please note,
+ this directive is implemented only in version 1.37 and later. The
+ default is yes. We strongly recommend that you keep this set to yes
+ otherwise, when the last job has finished one part will remain in the
+ spool file and restore may or may not work.
\end{description}
\item [Device = \lt{}device-name\gt{}]
\index[dir]{Device}
\index[dir]{Directive!Device}
- This directive specifies the Storage daemon's name of the device resource
- to be used for the storage. This name is not the physical device name, but
- the logical device name as defined on the {\bf Name} directive contained in
- the {\bf Device} resource definition of the {\bf Storage daemon}
- configuration file or if the device is an Autochanger, you must put the
- name as defined on the {\bf Name} directive contained in the {\bf
- Autochanger} resource definition of the {\bf Storage daemon}. You can
- specify any name you would like (even the device name if you prefer) up to
- a maximum of 127 characters in length. The physical device name associated
- with this device is specified in the {\bf Storage daemon} configuration
- file (as {\bf Archive Device}). Please take care not to define two
- different Storage resource directives in the Director that point to the
- same Device in the Storage daemon. Doing so may cause the Storage daemon
- to block (or hang) attempting to open the same device that is already open.
- This directive is required.
+ This directive specifies the Storage daemon's name of the device
+ resource to be used for the storage. If you are using an Autochanger,
+ the name specified here should be the name of the Storage daemon's
+ Autochanger resource rather than the name of an individual device. This
+ name is not the physical device name, but the logical device name as
+ defined on the {\bf Name} directive contained in the {\bf Device} or the
+ {\bf Autochanger} resource definition of the {\bf Storage daemon}
+ configuration file. You can specify any name you would like (even the
+ device name if you prefer) up to a maximum of 127 characters in length.
+ The physical device name associated with this device is specified in the
+ {\bf Storage daemon} configuration file (as {\bf Archive Device}).
+ Please take care not to define two different Storage resource directives
+ in the Director that point to the same Device in the Storage daemon.
+ Doing so may cause the Storage daemon to block (or hang) attempting to
+ open the same device that is already open. This directive is required.
\label{MediaType}
\item [Media Type = \lt{}MediaType\gt{}]
cannot mount a Volume in any directory -- this can be done by creating
an appropriate soft link.
- Currently Bacula permits only a single Media Type. Consequently, if
+ Currently Bacula permits only a single Media Type per Storage
+ and Device definition. Consequently, if
you have a drive that supports more than one Media Type, you can
give a unique string to Volumes with different intrinsic Media
Type (Media Type = DDS-3-4 for DDS-3 and DDS-4 types), but then
find more on this subject in the \ilink{Basic Volume
Management}{DiskChapter} chapter of this manual.
- The {\bf MediaType} specified here, {\bf must} correspond to the {\bf
- Media Type} specified in the {\bf Device} resource of the {\bf Storage
- daemon} configuration file. This directive is required, and it is used
- by the Director and the Storage daemon to ensure that a Volume
- automatically selected from the Pool corresponds to the physical device.
- If a Storage daemon handles multiple devices (e.g. will write to
- various file Volumes on different partitions), this directive allows you
- to specify exactly which device.
+ The {\bf MediaType} specified in the Director's Storage resource, {\bf
+ must} correspond to the {\bf Media Type} specified in the {\bf Device}
+ resource of the {\bf Storage daemon} configuration file. This directive
+ is required, and it is used by the Director and the Storage daemon to
+ ensure that a Volume automatically selected from the Pool corresponds to
+ the physical device. If a Storage daemon handles multiple devices (e.g.
+ will write to various file Volumes on different partitions), this
+ directive allows you to specify exactly which device.
- As mentioned above, the value specified in the Director's Storage resource
- must agree with the value specified in the Device resource in the {\bf
- Storage daemon's} configuration file. It is also an additional check so that
- you don't try to write data for a DLT onto an 8mm device.
+ As mentioned above, the value specified in the Director's Storage
+ resource must agree with the value specified in the Device resource in
+ the {\bf Storage daemon's} configuration file. It is also an additional
+ check so that you don't try to write data for a DLT onto an 8mm device.
\label{Autochanger1}
\item [Autochanger = \lt{}yes|no\gt{}]
\index[dir]{Autochanger}
\index[dir]{Directive!Autochanger}
- If you specify {\bf yes} for this command (the default is {\bf no}), when
- you use the {\bf label} command or the {\bf add} command to create a new
- Volume, {\bf Bacula} will also request the Autochanger Slot number.
- This simplifies creating database entries for Volumes in an autochanger.
- If you forget to specify the Slot, the autochanger will not be used.
- However, you may modify the Slot associated with a Volume at any time by
- using the {\bf update volume} command in the console program. When {\bf
- autochanger} is enabled, the algorithm used by Bacula to search for
- available volumes will be modified to consider only Volumes that are
- known to be in the autochanger's magazine. If no {\bf in changer}
- volume is found, Bacula will attempt recycling, pruning, ..., and if
- still no volume is found, Bacula will search for any volume whether or
- not in the magazine. By privileging in changer volumes, this procedure
- minimizes operator intervention. The default is {\bf no}.
+ If you specify {\bf yes} for this command (the default is {\bf no}),
+ when you use the {\bf label} command or the {\bf add} command to create
+ a new Volume, {\bf Bacula} will also request the Autochanger Slot
+ number. This simplifies creating database entries for Volumes in an
+ autochanger. If you forget to specify the Slot, the autochanger will
+ not be used. However, you may modify the Slot associated with a Volume
+ at any time by using the {\bf update volume} or {\bf update slots}
+ command in the console program. When {\bf autochanger} is enabled, the
+ algorithm used by Bacula to search for available volumes will be
+ modified to consider only Volumes that are known to be in the
+ autochanger's magazine. If no {\bf in changer} volume is found, Bacula
+ will attempt recycling, pruning, ..., and if still no volume is found,
+ Bacula will search for any volume whether or not in the magazine. By
+ privileging in changer volumes, this procedure minimizes operator
+ intervention. The default is {\bf no}.
For the autochanger to be used, you must also specify {\bf Autochanger =
yes} in the \ilink{Device Resource}{Autochanger} in the Storage daemon's
configuration file as well as other important Storage daemon
configuration information. Please consult the \ilink{Using
- Autochangers}{AutochangersChapter} manual of this chapter for the details of
- using autochangers.
+ Autochangers}{AutochangersChapter} manual of this chapter for the
+ details of using autochangers.
\item [Maximum Concurrent Jobs = \lt{}number\gt{}]
\index[dir]{Maximum Concurrent Jobs}
\index[general]{Installing and Configuring SQLite }
\index[general]{SQLite!Installing and Configuring }
+Please note that SQLite both versions 2 and 3 are not network enabled,
+which means that they must be linked into the Director rather than accessed
+by the network as MySQL and PostgreSQL are. This has two consequences:
+\begin{enumerate}
+\item SQLite cannot be used in the {\bf bweb} web GUI package.
+\item If you use SQLite, and your Storage daemon is not on the same
+machine as your Director, you will need to transfer your database
+to the Storage daemon's machine before you can use any of the SD tools
+such as {\bf bscan}, ...
+\end{enumerate}
+
\section{Installing and Configuring SQLite -- Phase I}
\index[general]{Phase I!Installing and Configuring SQLite -- }
\index[general]{Installing and Configuring SQLite -- Phase I }
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}
-otherwise SQLite version 3.x is four to ten times slower than version 2.8.17.
-
Installing and Configuring is quite easy.
\begin{enumerate}
\index[general]{SQLite!Testing }
\index[general]{Testing SQLite }
-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.
+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