On Tuesday 06 February 2007 20:28, Martin Simmons wrote:
> >>>>> On Mon, 5 Feb 2007 16:28:24 +0100, Stephan Ebelt said:
> >
> > Hello,
> >
> > back in 1.38.11 I wrote this fileset which appeared to work quite nice.
> >
> > FileSet {
> > Name = "data-users-media"
> >
> > Include {
> > Options {
> > signature = md5
> > wilddir = "/home/*/Movies"
> > wilddir = "/home/*/Music"
> > wilddir = "/home/*/Pictures"
> > }
> >
> > # I do not want backup files
> > Options {
> > wildfile = "*~"
> > Exclude = yes
> > }
> > }
> > }
> >
> > Now, in bacula 2.0.1 it does not work anymore. Zero directories are
> > selected. Apparently this is because its missing a 'File = /home'
> > directive in the Include block.
> >
> > Adding this will select *all* files/dirs in /home which means I must
> > somehow exclude everything except the three directories I want. But I do
> > not know what to exclude exactly. There is just too much stuff in
> > multiple homes on multiple computers... so I try:
> >
> > FileSet {
> > Name = "data-users-media"
> >
> > Include {
> >
> > Options {
> > signature = md5
> > wilddir = "/home/*/Movies"
> > wilddir = "/home/*/Music"
> > wilddir = "/home/*/Pictures"
> > }
> >
> > Options {
> > wild = "/home*"
> > Exclude = yes
> > }
> >
> > File = /home
> > }
> > }
> >
> > (omitting the backup files for now)
> >
> > no luck. Only /home itself is selected. Nothing underneath. Also
> > experimenting with wilddir and wildfile in the exclude block does not
> > take me any further.
> >
> > Now I am trying to write a more-or-less complicated regexp to
> > revert-match the three dirs in the Exclude block at once. Something like:
> >
> > regexdir = "/home/.*/[^Movies|^Music|^Pictures]/.*"
> >
> > (though, this doesnt work yet)
>
> No, you can't use [] like that in a regexp -- it is for matching single
> characters, not strings. There is no "not" operator in regexps.
>
> > Somehow I am stuck here. Can someone see a more simple approach to get
> > _only_ those three directories from each home in the system? Or do I have
> > to write a script?
>
> This does most of what you want:
>
> FileSet {
> Name = "data-users-media"
>
> Include {
>
> Options {
> signature = md5
> wilddir = "/home/*/Movies"
> wild = "/home/*/Movies/*"
> wilddir = "/home/*/Music"
> wild = "/home/*/Music/*"
> wilddir = "/home/*/Pictures"
> wild = "/home/*/Pictures/*"
> }
>
> Options {
> wild = "/home/*/*"
> Exclude = yes
> }
>
> File = /home
> }
> }
>
> The only problem is that it also includes everything directly in /home, but
> that may not matter.
By the way, I am thinking of "removing" the default include all, so that in a
simple case, absolutely nothing will be included unless there is an explicit
Options { } that includes it. That would eliminate most of the confusions
with exclusion. However, that would be non-compatible.
>
> __Martin
>
> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache
> Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> Bacula-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/bacula-users
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Bacula-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bacula-users