Brebis 0.7, the fully automated backup checker

Follow me on  or Twitter 

The new version of Brebis “Chevillette” 0.7 was published two days ago. Brebis is a fully automated backup checkerBrebis 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.

What’s new?

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

Brebis is available in DebianFreeBSDArchlinux and Frugalware. Use your favorite package manager to install it.

How to install from the sources

# wget
# tar zxvf brebis-0.7.tar.gz && cd brebis-0.7
# python3.3 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:


We also save monthly-backup.conf in /etc/brebis:

# mv /backups/monthly-backup.conf /etc/brebis

Use 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
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

We at the Brebis Project welcome any feedback about Brebis. Feel free to subscribe to the Brebis-users mailing list, by Twitter or email me directly at

Official website:

2 thoughts on “Brebis 0.7, the fully automated backup checker

  1. “Brebis does not create backups”, alors oui je comprends mieux, Brebis ne fait pas les sauvegardes, il ne fait que “vérifier” la bonne santé de la sauvegarde, mais l’autre jour j’avais posé la question: est-ce que brebis peut vérifier la bonne santé d’une sauvegarde qui aurait été faite avec une application comme déja dup ?
    A pluche.

  2. anatolem : déja dup est un frontend à duplicity. Je ne sais pas pour deja dup mais duplicity propose le paramètre verify qui offre quelques fonctionnalités de vérification de l’état des sauvegardes. Pour aller plus loin(+ de paramètres de vérification,+ de types d’archives supportés), tu peux bien sûr utiliser Brebis sur les archives générées par duplicity.

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *