The new version of Brebis “Chevillette” 0.7 was published two days ago. Brebis is a fully automated backup checker. Brebis does not create backups. It only performs controls on them.
Brebis is able to detect a corrupted archive compressed with different formats, automatically checking the integrity of your archives and lots of parameters of the files inside these archives or inside a tree of files and provide detailed reports if unexpected states are detected. Check out the list of the supported features.
The main features of this new version are:
- new option -G or –gen-full to generate from you archive (or from your tree of files) the configuration file and the list of files you need to run Brebis.
- new parameter target to check the target of a link
Complete example of installing, configuring and running Brebis
How to install from your package manager
How to install from the sources
# wget http://brebisproject.org/attachments/download/8/brebis-0.7.tar.gz # tar zxvf brebis-0.7.tar.gz && cd brebis-0.7 # python3.3 setup.py install --install-scripts=/usr/bin # mkdir /etc/brebis
What you need before running brebis
Our goal is to check on a regular basis the archive /backups/monthly-backup.tar.gz.
Brebis needs two files in order to correctly run: a configuration file with general parameters and the list of files with all their parameters.
Don’t be afraid, both of theses files will be generated by Brebis with the following command:
# brebis -G /backups/monthly-backup.tar.gz # ls /backups/ monthly-backup.tar.gz monthly-backup.conf monthly-backup.list
All the files inside your archives have been detected and their names and parameters (uid, gid, mode, md5,…) have been written in the file monthly-backup.list. More information about those files.
How to configure Brebis
Lets save /backups/monthly-backup.list in /etc/brebis:
# mv /backups/monthly-backup.list /etc/brebis
For /backups/monthly-backup.conf, we just modify the files_list parameters:
[main] name=monthly-backup type=archive path=/backups/monthly-backup.tar.gz files_list=/etc/brebis/monthly-backup.list
We also save monthly-backup.conf in /etc/brebis:
# mv /backups/monthly-backup.conf /etc/brebis
Using Brebis is as simple as:
# brebis -c /etc/brebis/ -l /var/log/brebis.log
If there is not any difference between the current state of your backup and your list of file, the logfile /var/log/brebis.log will be empty. If any difference happens, they will be reported in /var/log/brebis.log.
Show time. I’m modifying the md5 hash sum of a file in /etc/brebis/monthly-backup.list, during the next run of brebis, I get the following content in brebis.log:
WARNING:root:1 file with unexpected hash while checking /backups/monthly-backup.tar.gz: WARNING:root:toto/titi hash is ce4f8cacd8fc702bdd03531b9447818b. Should have been ce4f8cacd8fc702bdd03531b94478184.
As you can read, Brebis reports a difference between what was expected and what it checks.
Now it’s easy to do the same for any backup you want to check on a regular basis. Just add something like the next line in /etc/crontab:
01 00 * * * root brebis -c /etc/brebis/ -l /var/log/brebis.log
A brebis run will happen every day at midnight to check your backup. Every configuration files in the directory /etc/brebis/ will be inspected.
Feedback about Brebis
Official website: http://www.brebisproject.org Mailing-list: http://lists.sourceforge.net/lists/listinfo/brebis-users