Paul writes:
> Saw a posing from a while back discussing the concept of letting users
> touch files to designate items to exclude from the backup. The
> discussion doesn't seem to have gotten far as the focus seemed to be on
> modifying BackupPC to support it. I've got another approach and wanted
> to get some feedback before I spent too much time on it.
>
> My thought is that I should be able to run a script via
> $Conf{DumpPreUserCmd} to create a list of files/dirs to exclude. The
> script would run 'find --type f -name .nobackup' for each entry in
> $shares. If the file were empty, the directory would be excluded.
> Non-empty .nobackup files would be expected to contain a list of entries
> in/under the current directory that should be excluded. Once the
> exclusion file exists, $TarClientCmd could be tweaked to add the
> "--exclude-from FILE" argument.
If you are using tar, it appears you can exclude directories
that contain a particular file with these options (this is
tar 1.18; not sure which prior versions have these options):
--exclude-tag=FILE exclude contents of directories containing FILE,
except for FILE itself
--exclude-tag-all=FILE exclude directories containing FILE
--exclude-tag-under=FILE exclude everything under directories
containing FILE
I haven't tested it though.
Craig
-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2005.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
BackupPC-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/backuppc-users
http://backuppc.sourceforge.net/