Hello,

On Friday 18 March 2005 23:56, David Fuchs wrote:
> Hello,
>
>  I've been trying to configure a FileSet that will only back up
> specific file extensions, but I seem to be misunderstanding the syntax of
> the FileSet records.
>
>  By searching the archives, I found the following FileSet example
> from someone else in the same situation.  In my effort to back up only
> certain file extensions (and exclude everything else by default) I came up
> with a very similar FileSet definition myself (only I'm specifying
> tarballs instead of M$ Office documents):
>

It was probably me who proposed something like the following.  I suspect it 
never worked because contrary to what I thought the exclude = yes matches 
nothing.  So,  I have two suggestions that may work:

1. Add a
     wild = "*"
   just after the exclude = yes

2. Alternatively, and probably better, add a

    regex = ".?*$"

   just after the exclude = yes.

I would be interested to know if this works or not.

>
>  FileSet {
>    Name = "std_workstation_lite"
>    Include {
>      Options {
>         wild = "*.doc"
>         wild = "*.xls"
>         compression = GZIP
>         signature = MD5
>      }
>      Options {
>         # match all files not matched by wild above
>         exclude = yes
>      }
>      File = "c:/Documents and Settings/"
>    }
>  }
>
>
>  I'll explain in my own words what I believe this definition does,
> so that my mistakes may be easy to point out.  To begin, the online manual
> states (with regard to filesets) a critical piece of information:
>
> "An Options resource that does not contain a wild directive is assumed to
> match any filename. This is important to understand, because once Bacula
> determine that the Options matches the file under consideration, that
> file will be saved without looking at any other Options resources that
> may be present."

This is why I thought the above would work, but I think in fact that the above 
is wrong. On the other hand, if one drops out of all the Options, and nothing 
has matched, then everything is matched, and the Options from the last 
Options are used (but apparently not the exclude -- I'm going to look into 
this).

>
>  First, the FileSet (example above) determines that "c:/Documents
> and Settings/" is to be backed up (recursively by default), contingent on
> the declared Options resources.
>
>  The first listed Options resource states that any .xls or .doc
> files will have GZIP compression applied, and will be fingerprinted with an
> MD5 signature.  If files with these two extensions are found, then the
> Options resource has a successful match, and the files are backed up after
> the options are applied (no more Options resources need be consulted - the
> manual says so).

Yes.

>
>  The second Options resource doesn't have any wild or regex, so we
> know that it matches ALL files (again, the manual says so).  
Probably not true.
> Additionally, 
> it has 'exclude' set to 'yes', meaning that any matching files will be
> excluded from the backup.  Finally, since Bacula will never consider this
> Options resource for .xls or .doc files (due to the first Options resource
> successfully matching them), then we must infer that all files except those
> will be excluded from the backup.
>
>  In practice, this type of configuration results in all files being
> backed up, no matter what their extension, even though the FileSet
> appears to be configured properly.  I'd very much like to know what I'm
> doing wrong here - your consideration in this matter is much appreciated!

Please let us know if my suggestions above help ...

>
> Thanks,
> -David Fuchs
>
>
>
>
> -------------------------------------------------------
> SF email is sponsored by - The IT Product Guide
> Read honest & candid reviews on hundreds of IT Products from real users.
> Discover which products truly live up to the hype. Start reading now.
> http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
> _______________________________________________
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users

-- 
Best regards,

Kern


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to