Bacula-users

Re: [Bacula-users] When does bacula use multiple tape drives

2014-03-31 13:41:51
Subject: Re: [Bacula-users] When does bacula use multiple tape drives
From: Josh Fisher <jfisher AT pvct DOT com>
To: bacula-users AT lists.sourceforge DOT net
Date: Mon, 31 Mar 2014 13:38:44 -0400
On 3/31/2014 12:04 PM, Randall Svancara wrote:
Hi,  

Looks like I can use both drives when I add 

  Changer Device = /dev/changer-sg2 

to the bacuala-sd.conf file

and additionally I had to add to the Storage directive

  Device = Qualstar

Yes, it is a little confusing. A 2-drive autochanger is really 3 physical devices and usually has 3 SCSI LUNs, one for each actual tape drive and one for the robot that moves tapes in and out of the tape drives. Bacula handles this with the Autochanger resource defined in bacula-sd.conf which serves two purposes. One is to define the SCSI LUN and script used to send commands to the tape robot. The other is to determine which Device resources are the autochanger's actual tape drives, or in other words the list of Device resources that Bacula may assign to jobs that are reading/writing to the Autochanger resource.

The actual tape drives in the autoloader are handled like any other tape drive with a Device resource definition in bacula-sd.conf. Thus the individual drives belonging to a multi-drive autoloader can be used as a stand-alone tape drive, if so desired, by specifying the SD's Device resource in the DIR's Storage resource. This is useful if there is a specific job that you want to dedicate a drive to. Perhaps there is a high priority job that is time constrained and must never have to wait on an available drive. In the normal use scenario, you specify the SD's Autochanger resource in the DIR's Storage resource, meaning that you want Bacula to select the first available drive and it doesn't matter which one gets selected.



# Definition of LTO tape storage device
Storage {
  Name =  "Qualstar"
  #Do not use "localhost" here
  Address = localhost                # N.B. Use a fully qualified name here
  SDPort = 9103
  Password = "haaaaahahahahahahahaahah"          # password for Storage daemon
  #Device = Drive-1                   # must be same as Device in Storage daemon
  #Device = Drive-2
  Device = Qualstar
  Media Type = LTO6                  # must be same as MediaType in Storage daemon
  Autochanger = yes                   # enable for autochanger device
  Maximum Concurrent Jobs = 2
}


In the bacula-dir.conf.  Apparently you have to reference the changer, not the actual tape devices like this example below.

  Device = Drive-1                   # must be same as Device in Storage daemon
  Device = Drive-2


I don't know what happens when two Device lines appear in the Storage resource. I suspect only one is used.


In terms of running multiple jobs, and writing to the same tape...this sounds like a pretty cool idea that Bacula can interleave the jobs.  How long has it been able to do this.  When I first used this software many years ago, it did not seem like this was available or maybe it was not advocated for reasons mentioned before. 

The only con with interleaving that I'm aware of is that it can make restores slow because it basically has to read all of the  interleaved job data in order to restore one job.


On Mon, Mar 31, 2014 at 8:58 AM, Wolfgang Denk <wd AT denx DOT de> wrote:
Dear John,

In message <CAEhu1-6BLDpXhGvzWaU+hqB2QH_TkDfL-ybOVP52CoPGZ6CVGA AT mail.gmail DOT com> you wrote:
>
> > bacula seems to only use one drive.  What determines in bacula when it is
> > optimal to use two drives?  I am using bacula Version: 5.2.13.  Additionally
> > I have set "Maximum Concurrent Jobs = 4" in all the relevant places, but all
> > this seems to do is allow multiple concurrent jobs run, which I have tested
> > and seems to work, but strangely, I was under the impression that one job
> > could write to one tape exclusively.  But in this case, it seems multiple
> > jobs can write to the same tape concurrently or is this not correct?  Lastly
> > I have specified spool directory, however it is never used.  Any ideas here
> > would be appreciated or clarity.
>
> Bacula can write to more than 1 drive at a time. However I believe by
> default bacula can not load the same pool into more than 1 drive at a
> time.

Yes, it can.

Best regards,

Wolfgang Denk

--
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd AT denx DOT de
Two wrongs don't make a right, but three rights make a left.



--
Randall Svancara



------------------------------------------------------------------------------


_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users

------------------------------------------------------------------------------
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users