I am doing something similar. I wrote small bash script that mounts the drive and runs rsync to copy the /var/lib/bareos folder to two USB drives that I rotate for offsite storage. The script is run daily by cron.

On 4/7/21 3:24 AM, Andy Feys wrote:
Thank you, I've found out which files to copy/rsync to disk. If I copy the full folder /var/lib/bareos I have everything I need, I think.


On Wednesday, March 31, 2021 at 4:29:50 PM UTC+2 Jon Schewe wrote:

    First, make sure that your bootstrap files get written to that
    drive. This will help with recovery.
    It might be helpful to have a database dump there as well.

    A couple of options.

    1) If your initial backups are using disk, you could just use
    rsync to keep the USB drive in sync at regular intervals.

    2) If you are using tape or don't want to use rsync, you can use a
    copy job to do offsite backups. I have a system setup that every 2
    weeks does a Virtual Full backup to the external drive and I take
    that drive offsite. The level for this job is "VirtualFull". The
    Storage and Virtual Full Pool properties are where you want to
    create the backup copy. The Pool attribute is where you want to
    copy from.
    Searching for virtualfull on
    https://docs.bareos.org/Configuration/Director.html provides some
    help.


    *Jon Schewe*

    Research Scientist

    *
    *C: +1 612.263.2718 <tel:(612)%20263-2718>

    O: +1 952.545.5720 <tel:(952)%20545-5720>

    [email protected]___

    *
    **Raytheon Technologies*

    Raytheon Intelligence & Space

    5775 Wayzata Blvd. Suite 630

    St. Louis Park, MN 55416


    _RTX.com <https://www.rtx.com/>_|_LinkedIn
    <https://www.linkedin.com/company/raytheontechnologies>_|_Twitter
    <https://twitter.com/raytheontech>_|_Instagram
    <https://www.instagram.com/raytheontechnologies>_


    ------------------------------------------------------------------------
    *From:* [email protected] <[email protected]> on
    behalf of Andy Feys <[email protected]>
    *Sent:* Wednesday, March 31, 2021 08:49
    *To:* bareos-users <[email protected]>
    *Subject:* [External] [bareos-users] How to copy the full backup
    to a USB hard drive weekly
    Hi,
    I am very new to Bareos, so this might be a very stupid question.
    But I haven't been able to get this to work and can't seem to find
    the correct info for this.

    I've succesfully installed two linux testservers, one acting as
    bareos server, the other uses bareos to backup its data to it.
    Both are ubuntu servers in case this matters.

    This setup works perfectly.

    Now I would like to test the next important thing (for us anyway):
    I want to copy the backups from the bareos server to a usb hard
    drive for offsite storage.

    Let's say I mount this hard disk in /extdisk.

    What would it take and how could I copy everything from the bareos
    server to this disk so I can restore it all in case the location
    where the server is stored burns to the ground.

    I have created a file in /etc/bareos/bareos-sd.d/device/ named
    USBStorage.conf with the following contents:

    Device {
    Name = USBStorage
    Media Type = File
    Archive Device = /extdisk
    LabelMedia = no;
    Random Access = yes;
    AutomaticMount = yes;
    RemoveableMedia = yes;
    AlwaysOpen = no;
    Description = "External USB drive"
    }

    I created a file USB.conf in /etc/bareos/bareos-dir.d/storage name
    USB.conf with the following contents:
    Storage {
      Name = USB
      Address = testubuntubareos
      Password = ""
      Device = USBStorage
      Media Type = File
    }

    bconsole reload works without error after this. And I can see
    "USB" in the Storage Devices section of the web-ui. But I don't
    know how to define a correct job to create a copy of everything
    onto USB.

    Does anyone have any info about this? Or interesting weblinks
    where I can find the relevant info?

    best regards, and thank you,
    Andy


-- You received this message because you are subscribed to the Google
    Groups "bareos-users" group.
    To unsubscribe from this group and stop receiving emails from it,
    send an email to [email protected].
    To view this discussion on the web visit
    
https://groups.google.com/d/msgid/bareos-users/1de0e5f4-0db5-46ff-8123-f2c8b4c097cfn%40googlegroups.com
    
<https://groups.google.com/d/msgid/bareos-users/1de0e5f4-0db5-46ff-8123-f2c8b4c097cfn%40googlegroups.com?utm_medium=email&utm_source=footer>.

--
You received this message because you are subscribed to the Google Groups "bareos-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected] <mailto:[email protected]>. To view this discussion on the web visit https://groups.google.com/d/msgid/bareos-users/709a3121-fadb-451a-ba20-ce5775c6d5e9n%40googlegroups.com <https://groups.google.com/d/msgid/bareos-users/709a3121-fadb-451a-ba20-ce5775c6d5e9n%40googlegroups.com?utm_medium=email&utm_source=footer>.

--

Rick Sutphin
Project Manager
Delta Technologies, Inc.
P.O. Box 2301
Tallahassee, FL 32316-2301
Ofc:  850.575.3977
Fax:  850.575.3908
Cell: 850.251.2345
https://delta-tech.com

Licenses: EF-20000414, ES-0000212 (FL) & LVU405002 (GA)

--
You received this message because you are subscribed to the Google Groups 
"bareos-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/bareos-users/b74f73f8-0845-c721-032a-0d9b62604eae%40delta-tech.com.

Reply via email to