backup of system using faubackup
In search of a usable system to make backup of my laptop and desktop system, I encountered faubackup.Faubackup is intended to be used to make backups towards a filesystem structure. I mean, you create a copy of your existing filesystem, thus files can easily be retrieved from the structure to restore. Your backup-storage can be consulted on-line. I - of course - would advise NOT to use this backup as life system :D.
Note that when altering a file in the source-system, faubackup copies the file again to the with the backup-time corresponding tree. The files that were not altered between backups are only hard-linked.
Negative side: regular backup will consume inodes for every directory, since unchanged directory-structures cannot be hardlinked (directory cannot be hardlinked to).
Now you can configure faubackup to ignore certain files and directories, based upon a nice matching-system..
This can be defined in the configuration file (defaults to /etc/faubackup.conf), but also in a per-directory possible .faubackuprc.
in /etc/faubackup you can define global rules like for instance don't backup backup files:
@ignore qw ( **/*.bak **/*.BAK )
Don't backup core files NOR backupfiles:
@ignore qw ( **/*.bak **/*.BAK **/core* )
You can also decide not to backup certain directories... This I did on directory base since otherwise this "global" rule might not have the intended result. Like if you'd decide not to backup tmp directory, this might be interesting not to bakcup in /root, but could be uninteresting in /mnt/c/cygwin.
So there I created a .faubackuprc for root:
/.faubackuprc
Ignore REGEXP:(.*/){0,1}[sS]ystem\ [vV]olume\ [iI]nformation
Ignore **/.Trash-* **/Recycled **/RECYCLER
Ignore dev proc srv sys
Ignore tmp
Ignore media
Ignore var/cache var/lock var/spool var/tmp
Ignore pagefile.sys hiberfil.sys
Especially the first line was a bit experimenting. It will cause faubackup to ignore all files and subdirectories in all following levels that have name "System Volume Information" (or variations with minor first character).
Because the specified file/directory-name contains spaces, apparently it has to be parsed through the perl-regexp combination and for this to work in combination with the check-on-all-directories, we needed to add the (.*/){0,1} which describes an optional (occurs once or not at all) prefix of a directory path. so (.*/) is the directory-match, which may occur at least zero and at most once (indication {0,1}).
0 Comments:
Post a Comment
<< Home