Multiple Storage Devices pointing to a single Tape Library

174 views
Skip to first unread message

Dmitri Sandler

unread,
May 4, 2021, 8:31:59 PM5/4/21
to bareos-users
Hello there,
I am new to the Bareos and hope someone can steer me to the right direction or point to documentation which might be able to help.

I am looking to set up a backup process which will process 350+ TB per week. I have a tape library with multiple tape drives. My plan was to set up 1x Bareos Director with 2x Bareos Storage Devices. Both of the Storage Devices would point to the same Autoloader but will have access to different tape drives. Each would get access to half of the tape drives. Is there a way to link both Storage Devices into a single storage on the Director, so that the Director knows that both have access to the same volumes?

Is there even a need to have multiple Storage Devices when using a single library or am I overthinking it? I am using VMs which would allow, with minimal configuration changes, migrate them to a different host.

I have tried:
Adding two addresses in the config file on the director. However, this results in only the second (last declared?) device being seen by the director.
Example of config:
Storage {
  Name = TAPE0
  Address = bareos-sd0
  Address = bareos-sd1
  Password = "password" #password is the same on both SD0 and SD1
  Device = AL0 #both SD0 and SD1 have the same autoloader configured (w/different tape drives)
  Media Type = LTO7
  Auto Changer = yes
}


Creating two files on the director which will contain the same storage name. But this results in error when attempting to create a duplicate.
bareos-dir: ERROR in lib/parse_conf.cc:305 Attempt to define second Storage resource named "TAPE0" is not permitted.
Example of config:
Storage {
  Name = TAPE0
  Address = bareos-sd0
  Password = "password" #password is the same on both SD0 and SD1
  Device = AL0 #both SD0 and SD1 have the same autoloader configured (w/different tape drives)
  Media Type = LTO7
  Auto Changer = yes
}
Storage {
  Name = TAPE0
  Address = bareos-sd1
  Password = "password" #password is the same on both SD0 and SD1
  Device = AL0 #both SD0 and SD1 have the same autoloader configured (w/different tape drives)
  Media Type = LTO7
  Auto Changer = yes
}


I also considered splitting the library into two virtual libraries with two separate autoloaders, but in that case they can't share the volumes which means in case I need to restore I cut the number of available tape drives in half.

Any recommendations and suggestions are much appreciated.

Bareos version: 20.0.1

Thank you,
   Dmitri
bareosTape.png

Brock Palen

unread,
May 4, 2021, 10:14:47 PM5/4/21
to Dmitri Sandler, bareos-users
Never done anything at your scale with Bareos, and only done it with 1 drive 8 slot loader.

I think you want to have just one storage, and that/s how baroes knows all the drives can access the same volumes, check over:

https://docs.bareos.org/TasksAndConcepts/AutochangerSupport.html
https://docs.bareos.org/Configuration/StorageDaemon.html#autochanger-resource

You define a storage type that’s has autochanges set to yes in your dir.conf

Storage {
Name = Tand-LTO5-Lib
Address = myth
Password = “<snip>"
Device = Tand-LTO5-Lib
Media Type = LTO5
Maximum Concurrent Jobs = 1 #update for number of drives
Auto Changer = yes
Heartbeat Interval = 60
}

In your sd config though define a device for each tape drive, and for the Autochange config in sd give it a list of devices.
This is in theory how this works, the autochanger metadevice has a list of tape drives it can use, and thus any drive can access the same Media type etc.

That’s where I would start.

Device {
Name = Tand-LTO5
Autochanger = yes
Drive Index = 0
Media Type = LTO5
Archive Device = /dev/nst1
Device Type = Tape
Maximum File Size = 20000000000 # 20 GB
Spool Directory = /mnt/spool/Tand-LTO5
Maximum Job Spool Size = 80000000000
Maximum Spool Size = 160000000000
Drive Crypto Enabled = Yes
Query Crypto Status = yes
Maximum Concurrent Jobs = 1
}

Autochanger {
Name = "Tand-LTO5-Lib"
Device = Tand-LTO5, Tand-LTO5-2, etc
Changer Device = /dev/sg7
Changer Command = "/usr/lib/bareos/scripts/mtx-changer %c %o %S %a %d"
}


Brock Palen
bro...@mlds-networks.com
www.mlds-networks.com
Websites, Linux, Hosting, Joomla, Consulting
> --
> 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 bareos-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/bareos-users/3a59b506-3bcd-4698-9452-0bc777507bf6n%40googlegroups.com.
> <bareosTape.png>

Reply all
Reply to author
Forward
0 new messages