Linux disaster recovery image backup

On this page

This page is for information purposes only. We are reworking completely the functionality of Linux DR image backup at the moment. For now, we do not recommend configuring and making Linux DR image backups using the backup agent.

Install Bacula

  1. Create new client configuration in the Management Console of the Backup & Disaster Recovery appliance, and then download .config file for the newly created client.

  2. Copy the .config and bacula.tar.gz files to the client computer.

  3. Follow instructions to install bacula-fd.

    tar zxf bacula.tar.gz && sudo ./bacula/install.sh
    
  4. Add bacula-fd to firewall exception list.

    You may find the official documentation here.

    1. If your system uses firewalld:

      sudo firewall-cmd -permanent -add-service=bacula-client
      
    2. If your system uses iptables:

      sudo iptables -I INPUT 1 -p tcp --dport 9102 -j ACCEPT
      sudo service iptables save && service iptables restart
      

Configure backup

  1. Do SSH key exchange with client target machine.

  2. SSH into appliance and then copy the public key of the mirror user to the client machine that you want.

    ssh-copy-id -i /cfg/users/mirror/.ssh/id_rsa.pub root@192.168.client.ip
    

    or

    cat /cfg/users/mirror/.ssh/id_rsa.pub
    
  3. Copy and paste that into its own line in the /root/.ssh/authorized_keys file on the client machine

  4. Make sure all Linux tools are installed

    1. If your system uses Yum package manager:

      ssh root@192.168.client.ip
      yum update -y && yum install -y
      rsync parted openssh-clients util-linux openssl
      
    2. If your system uses apt (Advanced Package Tool) package manager:

      ssh root@192.168.client.ip
      apt-get update -y && apt-get install -y
      rsync parted openssh-client util-linux openssl
      
  5. You can now do DR capturing.

Known issues

Some VMs failed to backup due to corrupted file system state on target machines.

JBD
IO error -5 recovering block 9187 in log
EXT4-fs error (device loop0): file system corruption
inode #8 logical block 9188 mapped to 467940 (size 1)
jbd2_journal_bmap
journal block not found at offset 9188 on loop0-8
JBD
bad block at offset 9188
JBD
IO error -5 recovering block 9188 in log
EXT4-fs error (device loop0): file system corruption
inode #8 logical block 9189 mapped to 467941 (size 1)
jbd2_journal_bmap
journal block not found at offset 9189 on loop0-8
JBD
bad block at offset 9189
JBD
recovery failed
EXT4-fs (loop0)
error loading journal

The fix was to run fsck on boot: sudo touch /forcefsck && reboot

Currently, appliance does not support operating systems with multiple LVM groups.