]> git.sur5r.net Git - bacula/docs/blobdiff - docs/manuals/en/concepts/newfeatures.tex
ebl Add chapter about statistics
[bacula/docs] / docs / manuals / en / concepts / newfeatures.tex
index 901c715ae02fc0d14573611c4a2be9fe1e94d8a9..b6943e69b756b2ec371f473907a2e4b74a618091 100644 (file)
@@ -146,6 +146,9 @@ run job=MyBackup level=VirtualFull
 And it would produce a new Full backup without using the client, and the output
 would be written to the {\bf Full} Pool which uses the Diskchanger Storage.
 
+If the Virtual Full is run, and there are no prior Jobs, the Virtual Full will
+fail with an error.
+
 \section{Duplicate Job Control}
 \index[general]{Duplicate Jobs}
 The new version of Bacula provides four new directives that
@@ -257,9 +260,9 @@ obey this flag.  The new directive is:
 The default value is {\bf no}.
 
 
-\section{Ignore Dir = \lt{}filename-string\gt{}}
+\section{Exclude Dirs Containing = \lt{}filename-string\gt{}}
 \index[general]{IgnoreDir}
-The {\bf Ignore Dir = \lt{}filename\gt{}} is a new directive that can be added to the Include
+The {\bf ExcludeDirsContaining = \lt{}filename\gt{}} is a new directive that can be added to the Include
 section of the FileSet resource.  If the specified
 filename is found on the Client in any directory to be backed up, 
 the whole directory will be ignored (not backed up).
@@ -274,7 +277,7 @@ For example:
         signature = MD5
       }
       File = /home
-      IgnoreDir = .excludeme
+      Exclude Dirs Containing = .excludeme
     }
   }
 \end{verbatim}
@@ -446,6 +449,12 @@ on the program called.
 
 \subsection{Concepts}
 
+Although it is possible to backup Exchange using Bacula VSS the Exchange 
+plugin adds a good deal of functionality, because while Bacula VSS
+completes a full backup (snapshot) of Exchange, it does
+not support Incremental or Differential backups, restoring is more
+complicated, and a single database restore is not possible.
+
 Microsoft Exchange organises its storage into Storage Groups with
 Databases inside them. A default installation of Exchange will have a
 single Storage Group called 'First Storage Group', with two Databases
@@ -464,7 +473,7 @@ plugin will not function if this option is enabled.
 The plugin allows backing up of entire storage groups, and the restoring
 of entire storage groups or individual databases. Backing up and
 restoring at the individual mailbox or email item is not supported but
-can be simulate by use of the Recovery Storage Group (see below).
+can be simulated by use of the "Recovery" Storage Group (see below).
 
 \subsection{Installing}
 
@@ -482,35 +491,66 @@ default Exchange installation.
 \subsection{Backup up}
 
 To back up an Exchange server the Fileset definition must contain at
-least 'Plugin = "exchange:/@EXCHANGE/Microsoft Information Store"' for
+least {\bf Plugin = "exchange:/@EXCHANGE/Microsoft Information Store"} for
 the backup to work correctly. The 'exchange:' bit tells Bacula to look
 for the exchange plugin, the '@EXCHANGE' bit makes sure all the backed
 up files are prefixed with something that isn't going to share a name
 with something outside the plugin, and the 'Microsoft Information Store'
 bit is required also. It is also possible to add the name of a storage
-group to the 'Plugin =' line, eg 'Plugin =
-"exchange:/@EXCHANGE/Microsoft Information Store/First Storage Group"'
+group to the "Plugin =" line, eg \\
+{\bf Plugin = "exchange:/@EXCHANGE/Microsoft Information Store/First Storage Group"} \\
 if you want only a single storage group backed up.
 
 Additionally, you can suffix the 'Plugin =' directive with
-':notrunconfull' which will tell the plugin not to truncate the Exchange
+":notrunconfull" which will tell the plugin not to truncate the Exchange
 database at the end of a full backup.
 
 An Incremental or Differential backup will backup only the database logs
-for each Storage Group by inspecting the 'modified date' on each
+for each Storage Group by inspecting the "modified date" on each
 physical log file. Because of the way the Exchange API works, the last
 logfile backed up on each backup will always be backed up by the next
 Incremental or Differential backup too. This adds 5MB to each
 Incremental or Differential backup size but otherwise does not cause any
 problems.
 
+By default, a normal VSS fileset containing all the drive letters will
+also back up the Exchange databases using VSS. This will interfere with
+the plugin and Exchange's shared ideas of when the last full backup was
+done, and may also truncate log files incorrectly. It is important,
+therefore, that the Exchange database files be excluded from the backup,
+although the folders the files are in should be included, or they will
+have to be recreated manually if a baremetal restore is done.
+
+\begin{verbatim}
+FileSet {
+   Include {
+      File = C:/Program Files/Exchsrvr/mdbdata
+      Plugin = "exchange:..."
+   }
+   Exclude {
+      File = C:/Program Files/Exchsrvr/mdbdata/E00.chk
+      File = C:/Program Files/Exchsrvr/mdbdata/E00.log
+      File = C:/Program Files/Exchsrvr/mdbdata/E000000F.log
+      File = C:/Program Files/Exchsrvr/mdbdata/E0000010.log
+      File = C:/Program Files/Exchsrvr/mdbdata/E0000011.log
+      File = C:/Program Files/Exchsrvr/mdbdata/E00tmp.log
+      File = C:/Program Files/Exchsrvr/mdbdata/priv1.edb
+   }
+}
+\end{verbatim}
+
+The advantage of excluding the above files is that you can significantly
+reduce the size of your backup since all the important Exchange files
+will be properly saved by the Plugin.
+
+
 \subsection{Restoring}
 
 The restore operation is much the same as a normal Bacula restore, with
 the following provisos:
 
 \begin{itemize}
-\item  The 'Where' restore option must not be specified
+\item  The {\bf Where} restore option must not be specified
 \item Each Database directory must be marked as a whole. You cannot just
      select (say) the .edb file and not the others.
 \item If a Storage Group is restored, the directory of the Storage Group
@@ -518,22 +558,24 @@ the following provisos:
 \item  It is possible to restore only a subset of the available log files,
      but they {\bf must} be contiguous. Exchange will fail to restore correctly
      if a log file is missing from the sequence of log files
-\item Each database to be restored must be dismounted and marked as 'Can be
-    overwritten by restore'
+\item Each database to be restored must be dismounted and marked as "Can be
+    overwritten by restore"
 \item If an entire Storage Group is to be restored (eg all databases and
    logs in the Storage Group), then it is best to manually delete the
-   database files from the server (eg C:\verb+\+Program Files\verb+\+Exchsrvr\verb+\+ mdbdata\verb+\+*)
+   database files from the server (eg C:\verb+\+Program Files\verb+\+Exchsrvr\verb+\+mdbdata\verb+\+*)
    as Exchange can get confused by stray log files lying around.
 \end{itemize}
 
 \subsection{Restoring to the Recovery Storage Group}
 
 The concept of the Recovery Storage Group is well documented by
-Microsoft (find a link and put it here), but to briefly summarise...
+Microsoft 
+\elink{http://support.microsoft.com/kb/824126}{http://support.microsoft.com/kb/824126}, 
+but to briefly summarize...
 
 Microsoft Exchange allows the creation of an additional Storage Group
 called the Recovery Storage Group, which is used to restore an older
-copy of a database (eg before a mailbox was deleted) into without
+copy of a database (e.g. before a mailbox was deleted) into without
 messing with the current live data. This is required as the Standard and
 Small Business Server versions of Exchange can not ordinarily have more
 than one Storage Group.
@@ -553,6 +595,10 @@ Then run the restore.
 
 \subsection{Caveats}
 
+This plugin is still being developed, so you should consider it
+currently in BETA test, and thus use in a production environment
+should be done only after very careful testing.
+
 The "Enable Circular Logging" option cannot be enabled or the plugin
 will fail.
 
@@ -566,6 +612,13 @@ The plugin will most likely not work well if another backup application
 (eg NTBACKUP) is backing up the Exchange database, especially if the
 other backup application is truncating the log files.
 
+The Exchange plugin has not been tested with the {\bf Accurate} option, so
+we recommend either carefully testing or that you avoid this option for
+the current time.
+
+The Exchange plugin is not called during processing the bconsole {\bf estimate} command,
+and so anything that would be backed up by the plugin will not be added
+to the estimate total that is displayed.
 
 
 \section{libdbi Framework}
@@ -649,7 +702,8 @@ following packages are needed:
 \section{Display Autochanger Content}
 \index[general]{StatusSlots}
 
-The {\bf status slots storage=\lt{}storage-name\gt{}} command displays autochanger content.
+The {\bf status slots storage=\lt{}storage-name\gt{}} command displays
+autochanger content.
 
 \footnotesize
 \begin{verbatim}
@@ -730,8 +784,8 @@ Job {
 }
 \end{verbatim}
 
-A new Client RunScript {\bf RunsWhen} keyword of {\bf AfterVSS} has been implemented, which
-runs the command after the Volume Shadow Copy has been made.
+A new Client RunScript {\bf RunsWhen} keyword of {\bf AfterVSS} has been
+implemented, which runs the command after the Volume Shadow Copy has been made.
 
 Console commands can be specified within a RunScript by using:
 {\bf Console = \lt{}command\gt{}}, however, this command has not been 
@@ -819,11 +873,11 @@ than your statistics period. Ie, if jobs are purged from the catalog, you won't
 be able to use them. 
 
 Now, you can use the \textbf{update stats [days=num]} console command to fill
-the JobStat table with new Job records. If you want to be sure to take in
+the JobHistory table with new Job records. If you want to be sure to take in
 account only \textbf{good jobs}, ie if one of your important job has failed but
 you have fixed the problem and restarted it on time, you probably want to
 delete the first \textit{bad} job record and keep only the successful one. For
-that simply let your staff do the job, and update JobStat table after two or
+that simply let your staff do the job, and update JobHistory table after two or
 three days depending on your organization using the \textbf{[days=num]} option.
 
 These statistics records aren't used for restoring, but mainly for
@@ -834,7 +888,7 @@ can also use tools like Talend or extract information by yourself.
 
 The {\textbf Statistics Retention = \lt{}time\gt{}} director directive defines
 the length of time that Bacula will keep statistics job records in the Catalog
-database after the Job End time. (In \texttt{JobStat} table) When this time
+database after the Job End time. (In \texttt{JobHistory} table) When this time
 period expires, and if user runs \texttt{prune stats} command, Bacula will
 prune (remove) Job records that are older than the specified period.
 
@@ -1057,9 +1111,9 @@ typedef struct s_baculaFuncs {
        int type, time_t mtime, const char *fmt, ...);
    bRC (*DebugMessage)(bpContext *ctx, const char *file, int line,
        int level, const char *fmt, ...);
-   void *(*malloc)(bpContext *ctx, const char *file, int line,
+   void *(*baculaMalloc)(bpContext *ctx, const char *file, int line,
        size_t size);
-   void (*free)(bpContext *ctx, const char *file, int line, void *mem);
+   void (*baculaFree)(bpContext *ctx, const char *file, int line, void *mem);
 } bFuncs;
 \end{verbatim}
 
@@ -1650,4 +1704,38 @@ should return:
   
 \end{description}
 
+\section{Bacula Plugin Entrypoints}
+When Bacula calls one of your plugin entrypoints, you can call back to
+the entrypoints in Bacula that were supplied during the xxx plugin call
+to get or set information within Bacula.
+
+\subsection{bRC registerBaculaEvents(bpContext *ctx, ...)}
+This Bacula entrypoint will allow you to register to receive events
+that are not autmatically passed to your plugin by default. This 
+entrypoint currently is unimplemented.
+
+\subsection{bRC getBaculaValue(bpContext *ctx, bVariable var, void *value)}
+Calling this entrypoint, you can obtain specific values that are available
+in Bacula.
+
+\subsection{bRC setBaculaValue(bpContext *ctx, bVariable var, void *value)}
+Calling this entrypoint allows you to set particular values in
+Bacula.
+
+\subsection{bRC JobMessage(bpContext *ctx, const char *file, int line,
+       int type, time\_t mtime, const char *fmt, ...)}
+This call permits you to put a message in the Job Report.
+
+
+\subsection{bRC DebugMessage)(bpContext *ctx, const char *file, int line,
+       int level, const char *fmt, ...)}
+This call permits you to print a debug message.
+
+
+\subsection{void baculaMalloc(bpContext *ctx, const char *file, int line,
+       size\_t size)}
+This call permits you to obtain memory from Bacula's memory allocator.
+
 
+\subsection{void baculaFree(bpContext *ctx, const char *file, int line, void *mem)}
+This call permits you to free memory obtained from Bacula's memory allocator.