Op 20121017 om 10:16 schreef lst_ho...@kwsoft.de: > Zitat von Geert Stappers <geert.stapp...@vanadgroup.com>: > > > Hello Bacula Users, > > > > Where I don't want to backup logfiles, > > I do want to restore empty log directory trees. > > > > How to define a FileSet that matches > > find /var/log -type d > > > > You might try a wildfile directive which matches *all* files for > exclusion. As it should only be applied to files the directories > should not be affected. >
I couldn't write that into a file set definition. My efforts would bring me all the log files :-( | *estimate job=**** | Using Catalog "MyCatalog" | Connecting to Client ***-fd at ****:9102 | 2000 OK estimate files=684277 bytes=47,077,206,076 | *reload | *estimate job=**** | Using Catalog "MyCatalog" | Connecting to Client ***-fd at ****:9102 | 2000 OK estimate files=685768 bytes=50,348,262,388 Also I did spend time on another approach. It involves an action at client side. In the bash shell I did for D in $( find /var/log -type d ); do echo "but not all the log files in it" > $D/.restorethislogdirectory; do The result is like | # find /var/log -name .restorethislogdirectory | tail -n 6 | /var/log/pm/.restorethislogdirectory | /var/log/cups/.restorethislogdirectory | /var/log/news/.restorethislogdirectory | /var/log/httpd/.restorethislogdirectory | /var/log/puppet/.restorethislogdirectory | /var/log/prelink/.restorethislogdirectory And at Bacula server side had I a fileset like | FileSet { Name = "rootbootvar" | Include { | Options { | signature = MD5 | } | File = / | File = /boot | File = /var | File = /var/spool/cron | } | Exclude { | File = /proc | File = /tmp | File = /var/log | File = /var/spool | File = /.journal | File = /.fsck | } | } And did change that into | FileSet { Name = "rootbootvar" | Include { | Options { | signature = MD5 | } | File = / | File = /boot | File = /var | File = /var/spool/cron | } | Exclude { | Options { | Exclude = "no" | Wild = "/var/log/*/.restorethislogdirectory" | } | File = /proc | File = /tmp | File = /var/log | File = /var/spool | File = /.journal | File = /.fsck | } | } But with no effect. Other attempts with | Wild = "/var/log/*/.restorethislogdirectory" couldn't persuade Bacula to backup those hidden files. More hints how to get /var/log directories during restore are very welcome Cheers Geert Stappers -- http://www.vanadcimplicity.com/ ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_sfd2d_oct _______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users