Changes for page Bacula
Last modified by Sebastian Marsching on 2022/06/21 21:12
From version 5.1
edited by Sebastian Marsching
on 2022/06/21 21:12
on 2022/06/21 21:12
Change comment:
There is no comment for this version
To version 1.2
edited by Sebastian Marsching
on 2022/02/06 22:32
on 2022/02/06 22:32
Change comment:
Added tag [Windows]
Summary
-
Page properties (2 modified, 0 added, 0 removed)
Details
- Page properties
-
- Tags
-
... ... @@ -1,1 +1,1 @@ 1 -Windows |Linux1 +Windows - Content
-
... ... @@ -1,7 +1,5 @@ 1 1 {{info}} 2 2 While the information compiled on this page was originally intended for Bacula, most of it should also apply to Bareos. 3 - 4 -There is a [[separate page with information about Bareos|doc:Software.Bareos.WebHome]], and some of the information there might also apply to Bacula. 5 5 {{/info}} 6 6 7 7 {{toc/}} ... ... @@ -391,7 +391,7 @@ 391 391 392 392 # Labeling Volumes Automatically 393 393 394 -For creating labels for new volumes automatically in an autochanger setup, you can use the `label 392 +For creating labels for new volumes automatically in an autochanger setup, you can use the `label barcodes` command in bconsole. 395 395 396 396 # Recovering an error volume 397 397 ... ... @@ -411,37 +411,27 @@ 411 411 412 412 ## Step-by-Step Guide 413 413 414 -We have to build a Windows 7 x64 image using [WinBuilder](http://winbuilder.net/) / [multiPE](http://reboot.pro/files/file/61-multipe) (x86 might also work). The German computer magazine [PC-Welt](http://www.pcwelt.de/) provides a [nice download bundle](http://www.pcwelt.de/downloads/PC-WELT_Multi-PE-Windows-Rettungssystem-7053993.html) that contains everything needed (apart from the Windows system itself of course). It is important to include the Visual C++ runtime (with 32-bit compatibility support). This option named "Force x86 SideBySide For 64-Bit Operation Systems" can be found in WinBuilder under "VC++ 2008". A PE-disk based on Windows XP might not work, because Windows XP did not support Junction Points (although the support for them has been in NTFS for decades), so Bacula might not be able to restore them. If we have a NIC or disk controller that is not natively supported by Windows, we have to include the corresponding drivers in the PE disk because otherwise we will not be able to restore the backup later. 412 +1. We have to build a Windows 7 x64 image using [WinBuilder](http://winbuilder.net/) / [multiPE](http://reboot.pro/files/file/61-multipe) (x86 might also work). The German computer magazine [PC-Welt](http://www.pcwelt.de/) provides a [nice download bundle](http://www.pcwelt.de/downloads/PC-WELT_Multi-PE-Windows-Rettungssystem-7053993.html) that contains everything needed (apart from the Windows system itself of course). It is important to include the Visual C++ runtime (with 32-bit compatibility support). This option named "Force x86 SideBySide For 64-Bit Operation Systems" can be found in WinBuilder under "VC++ 2008". A PE-disk based on Windows XP might not work, because Windows XP did not support Junction Points (although the support for them has been in NTFS for decades), so Bacula might not be able to restore them. If we have a NIC or disk controller that is not natively supported by Windows, we have to include the corresponding drivers in the PE disk because otherwise we will not be able to restore the backup later. 413 +1. First we have to boot from the operating-system installation-disk and install the OS the same way we would for a new system. However, to save some time, we can use the "Server Core" installation because we only do this to create partitions and to restore the boot loader. We stop the installation process at the time of the first reboot. 414 +1. Now we boot from the PE-disk created with WinBuilder. We assign the C: drive letter to the new system partition on the hard-disk (using Disk Management), so that Bacula will restore the files to the right partition. 415 +1. We format the C: drive, so that the files that were just created by the installer are deleted. 416 +1. Now we have to download and install the Bacula File Daemon. It makes sense to use the same version of the Bacula FD that was used to create the Backup. For a 64-bit PE-disk we use the 64-bit version of Bacula. We use an installation path that for sure does not exist in the image to be restored (e.g. `C:\BaculaJustForRestore`). If we used the default path, we would get a collission with the Bacula files that are part of the restore. We remove the checkmarks on the "Install as service" and "Start after install" options because we will take care of starting Bacula manually once we have adjusted the configuration. 417 +1. After the installation has finished, we open the `bacula-fd.conf` file and make sure that the configuration is correct: Basically, we want the same settings here that we had on the original system. In particular, the client name, director name and password should match. We also have to make sure that the paths for the working and PID directories point to the correct (non-standard) directory. 418 +1. Finally, we have to ensure that the IP address of the system is set correctly. If the IP address does not match the address in the Bacula director configuration, we can either change the director configuration or manually configure the IP address of the system. 419 +1. 415 415 416 -First we have to boot from the operating-system installation-disk and install the OS the same way we would for a new system. However, to save some time, we can use the "Server Core" installation because we only do this to create partitions and to restore the boot loader. We stop the installation process at the time of the first reboot. 417 - 418 -Now we boot from the PE-disk created with WinBuilder. We assign the C: drive letter to the new system partition on the hard-disk (using Disk Management), so that Bacula will restore the files to the right partition. 419 - 420 -We format the C: drive, so that the files that were just created by the installer are deleted. 421 - 422 -Now we have to download and install the Bacula File Daemon. It makes sense to use the same version of the Bacula FD that was used to create the Backup. For a 64-bit PE-disk we use the 64-bit version of Bacula. We use an installation path that for sure does not exist in the image to be restored (e.g. `C:\BaculaJustForRestore`). If we used the default path, we would get a collission with the Bacula files that are part of the restore. We remove the checkmarks on the "Install as service" and "Start after install" options because we will take care of starting Bacula manually once we have adjusted the configuration. 423 - 424 -After the installation has finished, we open the `bacula-fd.conf` file and make sure that the configuration is correct: Basically, we want the same settings here that we had on the original system. In particular, the client name, director name and password should match. We also have to make sure that the paths for the working and PID directories point to the correct (non-standard) directory. 425 - 426 -Finally, we have to ensure that the IP address of the system is set correctly. If the IP address does not match the address in the Bacula director configuration, we can either change the director configuration or manually configure the IP address of the system. 427 - 428 -Now we start the Bacula FD by opening a command prompt, changing to the installation directory and running `bacula-fd.exe` with the right command-line parameters. Example: 429 - 430 -```bat 431 -c: 421 +Now we start the Bacula FD by opening a command prompt, changing to the installation directory and running `bacula-fd.exe` with the right command-line parameters. Example: 422 +`c: 432 432 cd BaculaJustForRestore 433 -bacula-fd /run -c C:\BaculaJustForRestore\bacula-fd.conf 434 -``` 424 +bacula-fd /run -c C:\BaculaJustForRestore\bacula-fd.conf` 425 +1. Now we are ready to start the restore in the Bacula console. We have to select the whole C: drive (but no other drives - we can restore them later). In the restore options we set an empty prefix ("/") for the target location ("Where:"), so that the files are restored to their original location on the C: drive. 426 +1. When the restore has completed, we shut the computer down and remove the PE-disk. That’s it. The next time we boot the computer the restored system should boot. After that, we can delete the temporary Bacula installation and restore the files on other disks (if there are any). 435 435 436 - Nowweareeadytostarttherestore in theBaculaconsole. Wehavetoselect thewholeC:drive(butno otherdrives-we canrestore themlater). Inthe restoreoptionswe setn empty prefix("/")forthetargetlocation("Where:"),sothatthe files arerestoredto theiroriginallocationontheC:drive.428 +If the computer does not boot the system in step 10, the first thing I would try would be to boot from OS installation disk and use `startrep.exe` in repair mode. However, this is not a part of this guide, because for me it worked right away. 437 437 438 -When the restore has completed, we shut the computer down and remove the PE-disk. That’s it. The next time we boot the computer the restored system should boot. After that, we can delete the temporary Bacula installation and restore the files on other disks (if there are any). 439 - 440 -If the computer does not boot the system in the last step, the first thing I would try would be to boot from OS installation disk and use `startrep.exe` in repair mode. However, this is not a part of this guide, because for me it worked right away. 441 - 442 442 # Making a system state backup using Windows Server Backup 443 443 444 -If you want to make a system state backup using Windows Server Backup each time that you make a backup with Bacula, you might find the following script useful, that you can add as a `run 432 +If you want to make a system state backup using Windows Server Backup each time that you make a backup with Bacula, you might find the following script useful, that you can add as a `run before job` script. 445 445 446 446 ```bat 447 447 @echo off