Bareos Bare Metal Restore [B-BMR]

Who?

If you haven’t done the first use section, do this first… I hope you have your jobs under your own control (you known which saved data snapshot is in differnet jobs)

Generally

You have to authentication via LDAP so you can use your normal BFH Account (BFH-Username and BFH-Password, BFH-Kürzel and BFH-PW) to login with So enter these authentication information into the B-BMRestore.sh script, if you would be asked

Summarised disaster recovery steps

Read this chapter, to become an overview of tasks for restoring physical clients

+ organize the b-bmr.iso file for booting your corrupt/failed system
+ The disaster recorery medium [B-BMR.iso] is available on several places; https://wiki.bfh.ch/, https://bareos.bfh.ch/download/ etc.
+ When you boot the B-BMR.iso image via a medium, select the boot-option "live"
+ press 3-4 times enter (to be sure your interact with an running shell)
+ run the command "ls" to look for the B-BMRestore.sh Script...
+ Find the B-BMRestore.sh Script in the home folder/directory from the restoreusr. Full-Path:"/home/restoreusr/B-BMRestore.sh"
+ When your already in this directory, you can enter the command "./B-BMRestore.sh" to start the software
+ When your not in the /home/restoreusr/ folder, you can easily push this command "./home/restoreusr/B-BMRestore.sh"

How?

Restore Client (disaster recovery steps more detailed)

Do this chapter, if your physical computer/server doesn’t start/boot

+ Boot with iso
  Download iso, write iso on device, check your BIOS options, boot from device where the iso file is written

+ run B-BMRestore.sh Script
  $ ./home/restoreusr/B-BMRestore.sh

+ configure restore
  choose your restorebjob options in the B-BMRestore Script

+ wait until the bareos restore job is finished
  Full-backup below 5 GB can be restored in 10 minutes

Download B-BMR.iso:

$ scp prepare@bareos.bfh.ch:/home/prepare/B-BMR.iso /tmp/.

write ISO image on medium (/dev/sdb is my usb stick)

$ dd if="/tmp/B-BMR.iso" of="/dev/sdb"
Plugin your usb device and control your BIOS or UEFI boot options
(choose BOOT FROM USB DEVICE)

Run the script: Press 3-4 times enter, to be sure, your’re entering on a bash shell then type in this command:

$ ./home/restoreusr/B-BMRestore.sh
Do a full backup
--> log in via website GUI https://bareos.bfh.ch/_
---> Go to Jobs -> Then Actions
----> Start the backup job, with the FQDN of your System
Control if the full backup works:
Befor you will start an incremental backup job, you create a file with this command:
$ echo "$(date) $USER" > test.txt # It write the current date and the user name in it

Start the incremental backup job or a full After the backup job is finished, delete on the client system the test.txt, so can check if your backup works, because

Restore the text.txt file with backup job you just have done. When now the test.txt file exists, then your backup system works well :)

Now you can Test the B-BMR Medium, to be sure that your disaster recovery medium works

How to use B-BMR

Do this chapter, if you haven’t used bareos before

Bare Metal Restore with Bareos => Bareos Bare Metal Restore
==> B-BMR [the iso file you can write to an usb device, with CLI-tools like "dd" or on windows "Win32DiskImager"]
With B-BMR you can restore your bareos client configuration from a repository, the paritions table is also saved there

To create restore media/medium, you only have to:

* run the B-BMR-Prepare.sh script
* with the prepare script you will configure the bareos client and transmit the bareos client configuraion files with the partitions table from your local system to the bareos server
* do a full backup (that's an one to one copy of your current local bareos client system)
* Restore some files (to be sure, that the backup works, to be really sure, test the disaster recovery medium [run B-BMR, but fist do all other steps])