]> git.sur5r.net Git - bacula/docs/blobdiff - docs/manuals/en/main/newfeatures.tex
Remove checksum for accurate fileset option
[bacula/docs] / docs / manuals / en / main / newfeatures.tex
index ffb55804a8f78d9301577ffdafb380279b179d1d..02524f15d75424e81bfcf9186c43bd795bf22f53 100644 (file)
@@ -1,3 +1,231 @@
+\chapter{New Features in 5.1.x}
+This chapter presents the new features that have been added to the
+current version of Bacula that is under development. This version will be
+released at some later date, probably near the end of 2010.
+
+\section{Changes in the pruning algorithm}
+
+We rewrote the job pruning algorithm in this version. Previously, in some users
+reported that the pruning process at the end of jobs was very long. It should
+not be longer the case. Now, Bacula won't prune automatically a Job if this
+particular Job is needed to restore data. Example:
+
+\begin{verbatim}
+JobId: 1  Level: Full
+JobId: 2  Level: Incremental
+JobId: 3  Level: Incremental
+JobId: 4  Level: Differential
+.. Other incrementals up to now
+\end{verbatim}
+
+In this example, if the Job Retention defined in the Pool or in the Client
+resource causes that Jobs with Jobid in 1,2,3,4 can be pruned, Bacula will
+detect that JobId 1 and 4 are essential to restore data at the current state
+and will prune only JobId 2 and 3.
+
+\texttt{Important}, this change affect only the automatic pruning step after a
+Job and the \texttt{prune jobs} Bconsole command. If a volume expires after the
+\texttt{VolumeRetention} period, important jobs can be pruned.
+
+\section{Ability to Verify any specified Job}
+You now have the ability to tell Bacula which Job should verify instead of
+automatically verify just the last one.
+
+This feature can be used with VolumeToCatalog, DiskToCatalog and Catalog level.
+
+To verify a given job, just specify the Job jobid in argument when starting the
+job.
+\begin{verbatim}
+*run job=VerifyVolume jobid=1 level=VolumeToCatalog
+Run Verify job
+JobName:     VerifyVolume
+Level:       VolumeToCatalog
+Client:      127.0.0.1-fd
+FileSet:     Full Set
+Pool:        Default (From Job resource)
+Storage:     File (From Job resource)
+Verify Job:  VerifyVol.2010-09-08_14.17.17_03
+Verify List: /tmp/regress/working/VerifyVol.bsr
+When:        2010-09-08 14:17:31
+Priority:    10
+OK to run? (yes/mod/no):
+\end{verbatim}
+
+\section{Additions to the Plugin API}
+The bfuncs structure has been extended to include a number of
+new entrypoints.
+
+\subsection{bfuncs}
+The bFuncs structure defines the callback entry points within Bacula
+that the plugin can use register events, get Bacula values, set
+Bacula values, and send messages to the Job output or debug output.
+
+The exact definition as of this writing is:
+\begin{verbatim}
+typedef struct s_baculaFuncs {
+   uint32_t size;
+   uint32_t version;
+   bRC (*registerBaculaEvents)(bpContext *ctx, ...);
+   bRC (*getBaculaValue)(bpContext *ctx, bVariable var, void *value);
+   bRC (*setBaculaValue)(bpContext *ctx, bVariable var, void *value);
+   bRC (*JobMessage)(bpContext *ctx, const char *file, int line,
+       int type, utime_t mtime, const char *fmt, ...);
+   bRC (*DebugMessage)(bpContext *ctx, const char *file, int line,
+       int level, const char *fmt, ...);
+   void *(*baculaMalloc)(bpContext *ctx, const char *file, int line,
+       size_t size);
+   void (*baculaFree)(bpContext *ctx, const char *file, int line, void *mem);
+   
+   /* New functions follow */
+   bRC (*AddExclude)(bpContext *ctx, const char *file);
+   bRC (*AddInclude)(bpContext *ctx, const char *file);
+   bRC (*AddIncludeOptions)(bpContext *ctx, const char *opts);
+   bRC (*AddRegexToInclude)(bpContext *ctx, const char *item, int type);
+   bRC (*AddWildToInclude)(bpContext *ctx, const char *item, int type);
+
+} bFuncs;
+\end{verbatim}
+
+\begin{description}
+\item [AddExclude] can be called to exclude a file. The file
+  string passed may include wildcards that will be interpreted by
+  the {\bf fnmatch} subroutine. This function can be called 
+  multiple times, and each time the file specified will be added
+  to the list of files to be excluded. Note, this function only
+  permits adding excludes of specific file or directory names,
+  or files matched by the rather simple fnmatch mechanism.
+  See below for information on doing wild-card and regex excludes.
+
+\item [NewInclude] can be called to create a new Include block. This
+  block will be added before any user defined Include blocks. This
+  function can be called multiple times, but each time, it will create
+  a new Include section (not normally needed). This function should
+  be called only if you want to add an entirely new Include block.
+
+\item [AddInclude] can be called to add new files/directories to
+  be included.  They are added to the current Include block. If
+  NewInclude has not been included, the current Include block is
+  the last one that the user created. This function
+  should be used only if you want to add totally new files/directories
+  to be included in the backup. 
+
+\item [NewOptions] adds a new Options block to the current Include
+  in front of any other Options blocks. This permits the plugin to
+  add exclude directives (wild-cards and regexes) in front of the
+  user Options, and thus prevent certain files from being backed up.
+  This can be useful if the plugin backs up files, and they should
+  not be also backed up by the main Bacula code.  This function
+  may be called multiple times, and each time, it creates a new
+  prepended Options block. Note: normally you want to call this 
+  entry point prior to calling AddOptions, AddRegex, or AddWild.
+  
+\item [AddOptions] allows the plugin it set options in
+  the current Options block, which is normally created with the
+  NewOptions call just prior to adding Include Options.
+  The permitted options are passed as a character string, where
+  each character has a specific meaning as defined below:
+
+  \begin{description}
+  \item [a] always replace files (default).
+  \item [e] exclude rather than include.
+  \item [h] no recursion into subdirectories.
+  \item [H] do not handle hard links.
+  \item [i] ignore case in wildcard and regex matches.
+  \item [M] compute an MD5 sum.
+  \item [p] use a portable data format on Windows (not recommended).
+  \item [R] backup resource forks and Findr Info.
+  \item [r] read from a fifo
+  \item [S1] compute an SHA1 sum.
+  \item [S2] compute an SHA256 sum.
+  \item [S3] comput an SHA512 sum.
+  \item [s] handle sparse files.
+  \item [m] use st\_mtime only for file differences.
+  \item [k] restore the st\_atime after accessing a file.
+  \item [A] enable ACL backup.
+  \item [Vxxx:] specify verify options. Must terminate with :
+  \item [Cxxx:] specify accurate options. Must terminate with :
+  \item [Jxxx:] specify base job Options. Must terminate with :
+  \item [Pnnn:] specify integer nnn paths to strip. Must terminate with :
+  \item [w] if newer
+  \item [Zn] specify gzip compression level n.
+  \item [K] do not use st\_atime in backup decision.
+  \item [c] check if file changed during backup.
+  \item [N] honor no dump flag.
+  \item [X] enable backup of extended attributes.
+  \end{description}
+
+\item [AddRegex] adds a regex expression to the current Options block.
+  The fillowing options are permitted:
+  \begin{description}
+  \item [ ] (a blank) regex applies to whole path and filename.
+  \item [F] regex applies only to the filename (directory or path stripped).
+  \item [D] regex applies only to the directory (path) part of the name.
+  \end{description}
+
+\item [AddWild] adds a wildcard expression to the current Options block.
+  The fillowing options are permitted:
+  \begin{description}
+  \item [ ] (a blank) regex applies to whole path and filename.
+  \item [F] regex applies only to the filename (directory or path stripped).
+  \item [D] regex applies only to the directory (path) part of the name.
+  \end{description}
+  
+\end{description}
+  
+
+\subsection{Bacula events}
+The list of events has been extended to include:
+
+\begin{verbatim}
+typedef enum {
+  bEventJobStart        = 1,
+  bEventJobEnd          = 2,
+  bEventStartBackupJob  = 3,
+  bEventEndBackupJob    = 4,
+  bEventStartRestoreJob = 5,
+  bEventEndRestoreJob   = 6,
+  bEventStartVerifyJob  = 7,
+  bEventEndVerifyJob    = 8,
+  bEventBackupCommand   = 9,
+  bEventRestoreCommand  = 10,
+  bEventLevel           = 11,
+  bEventSince           = 12,
+   
+  /* New events */
+  bEventCancelCommand                   = 13,
+  bEventVssBackupAddComponents          = 14,
+  bEventVssRestoreLoadComponentMetadata = 15,
+  bEventVssRestoreSetComponentsSelected = 16,
+  bEventRestoreObject                   = 17,
+  bEventEndFileSet                      = 18
+
+} bEventType;
+\end{verbatim}
+
+\begin{description}
+\item [bEventCancelCommand] is called whenever the currently
+  running Job is cancelled */
+
+\item [bEventVssBackupAddComponents] 
+
+\end{description}
+
+
+\chapter{Release Version 5.0.3}
+
+There are no new features in version 5.0.2.  This version simply fixes a
+number of bugs found in version 5.0.1 during the onging development
+process.
+
+\chapter{Release Version 5.0.2}
+
+There are no new features in version 5.0.2.  This version simply fixes a
+number of bugs found in version 5.0.1 during the onging development
+process.
+
+%%
+%%
+
 \chapter{New Features in 5.0.1}
 
 This chapter presents the new features that are in the released Bacula version
@@ -148,7 +376,7 @@ FileSet {
   Include = {
     Options {
        BaseJob  = pmugcs5
-       Accurate = mcs5
+       Accurate = mcs
        Verify   = pin5
     }
     File = /
@@ -203,7 +431,7 @@ FileSet {
   Name = Full
   Include = {
     Options {
-       Accurate = mcs5
+       Accurate = mcs
        Verify   = pin5
     }
     File = /
@@ -252,15 +480,24 @@ The new bconsole won't be able to tab-complete with older directors.
 
 This project was funded by Bacula Systems.
 
-\section{Pool File and Job retention}
+\section{Pool File and Job Retention}
 \label{sec:poolfilejobretention}
 
-% TODO check
 We added two new Pool directives, \texttt{FileRetention} and
 \texttt{JobRetention}, that take precedence over Client directives of the same
 name. It allows you to control the Catalog pruning algorithm Pool by Pool. For
 example, you can decide to increase Retention times for Archive or OffSite Pool.
 
+It seems obvious to us, but apparently not to some users, that given the
+definition above that the Pool File and Job Retention periods is a global
+override for the normal Client based prunning, which means that when the
+Job is prunned, the prunning will apply globally to that particular Job.
+
+Currently, there is a bug in the implementation that causes any Pool 
+retention periods specified to apply to {\bf all} Pools for that
+particular Client.  Thus we suggest that you avoid using these two
+directives until this implementation problem is corrected.
+
 \section{Read-only File Daemon using capabilities}
 \label{sec:fdreadonly}
 This feature implements support of keeping \textbf{ReadAll} capabilities after
@@ -1473,6 +1710,9 @@ plugin.
 The {\bf bpipe} plugin is provided in the directory src/plugins/fd/bpipe-fd.c of
 the Bacula source distribution. When the plugin is compiled and linking into
 the resulting dynamic shared object (DSO), it will have the name {\bf bpipe-fd.so}.
+Please note that this is a very simple plugin that was written for
+demonstration and test purposes. It is and can be used in production, but
+that was never really intended.
 
 The purpose of the plugin is to provide an interface to any system program for
 backup and restore. As specified above the {\bf bpipe} plugin is specified in
@@ -1500,13 +1740,24 @@ a conflict with a path and filename that actually exists on your system.
 \item {\bf field3} for the {\bf bpipe} plugin 
 specifies the "reader" program that is called by the plugin during
 backup to read the data. {\bf bpipe} will call this program by doing a
-{\bf popen} on it.
+{\bf popen} on it. 
 
 \item {\bf field4} for the {\bf bpipe} plugin
 specifies the "writer" program that is called by the plugin during
 restore to write the data back to the filesystem.  
 \end{description}
 
+Please note that for two items above describing the "reader" and "writer"
+fields, these programs are "executed" by Bacula, which
+means there is no shell interpretation of any command line arguments
+you might use.  If you want to use shell characters (redirection of input
+or output, ...), then we recommend that you put your command or commands
+in a shell script and execute the script. In addition if you backup a
+file with the reader program, when running the writer program during
+the restore, Bacula will not automatically create the path to the file.
+Either the path must exist, or you must explicitly do so with your command
+or in a shell script.
+
 Putting it all together, the full plugin directive line might look
 like the following:
 
@@ -2164,8 +2415,8 @@ transmitted across the network. That should reduce load and speedup insertion.
 A new Job directive permits to specify the spool size per job. This is used
 in advanced job tunning. {\bf SpoolSize={\it bytes}}
 
-\subsection{MaxConsoleConnections = \lt{}number\gt{}}
-\index[general]{MaxConsoleConnections}
+\subsection{MaximumConsoleConnections = \lt{}number\gt{}}
+\index[general]{MaximumConsoleConnections}
 A new director directive permits to specify the maximum number of Console
 Connections that could run concurrently. The default is set to 20, but you may
 set it to a larger number.