Bacula-users

Re: [Bacula-users] Quantum Superloader 3

2010-06-10 10:11:38
Subject: Re: [Bacula-users] Quantum Superloader 3
From: Bill Arlofski <waa-bacula AT revpol DOT com>
To: bwellsnc <bwellsnc AT gmail DOT com>, Bacula Users <bacula-users AT lists.sourceforge DOT net>
Date: Thu, 10 Jun 2010 10:09:29 -0400
bwellsnc  I have several clients with working Quantum Superloader3 tape
libraries. I think I know exactly what your problem is. :)

Since your mtx tests all work fine, and your bacula will backup to a tape when
you manually load it in,  here goes:


If you run "list media" I am guessing that you will also see that the "In
Changer" and "Slot" field for each of your volumes is "0" mening bacula does
not believe it to be somewhere it can get it to load by itself.

If you run the "update slots" command bacula should tell you what volumes it
THINKS are in the slots which should also indicate that bacula does not think
ANY of your media are in the Superloader.

I have a feeling that you manually labeled your tapes instead of using the
barcodes, and bacula does now know what slot it is supposed to load to get
"Tape-0241" (for instance) into the drive.

If you run the "label barcodes" command, bacula will automatically run through
each tape and write a bacula tape label matching the tape's barcode for each 
tape.

Then, whenever you remove/replace tapes you will need to run the update slots
command so that bacula can update the "Slot" and "in Changer" fields in the
database for your media.


I usually run a job of type "Admin" each night where my clients manually
insert/remove media tot their Quantum Superloader3's  that is configured to
run before (higher priority) than the nightly jobs and this "admin" job simply
runs a script that calls the "update slots" command so that bacula has
current/valid information regarding which tapes are in the Superloader and
which slot they are in.

Here's my "UpDateSlots" job Definition:

# ----------------
# Update Slots Job
# ----------------
Job {
  Name = UpDateSlots
  Client = backup-fd
  Type = Admin
  FileSet = None
  Storage = DLT-V4
  Schedule = UpDateSlots
  Messages = Standard
  Priority = 8
  SpoolData = no
  Pool = Default

  RunScript {
    RunsWhen = Before
    RunsOnClient = no
    Fail Job On Error = no
    Command = "/usr/local/sbin/runbefore-updateslots.sh"
  }
}


And here is the /usr/local/sbin/runbefore-updateslots.sh script that I use:

#!/bin/bash
#
# waa - 20091110
# --------------

BC="/usr/sbin/bconsole"
CONF="/etc/bacula/bconsole.conf"
STORAGE="DLT-V4"

$BC -c $CONF << WAAEOF
update slots storage=$STORAGE
quit
WAAEOF



Hope this helps.


--
Bill Arlofski
Reverse Polarity, LLC
http://www.revpol.com/




On 06/10/10 07:23, bwellsnc wrote:
> Yes, I was able to move the tapes perfectly fine from the command line using
> the mtx-changer script.  This is the error if I have no tape in the drive,
> but I have a tape in slot 1 of my autochanger:
> 
> 10-Jun 07:12 myservername-sd JobId 806: Invalid slot=0 defined in catalog
> for Volume "Tape-0241" on "DLT-S4" (/dev/st0). Manual load may be required.
> 10-Jun 07:12 myservername-sd JobId 806: 3301 Issuing autochanger "loaded?
> drive 0" command.
> *messages
> 10-Jun 07:12 myservername-sd JobId 806: 3302 Autochanger "loaded? drive 0",
> result: nothing loaded.
> 10-Jun 07:12 myservername-sd JobId 806: 3301 Issuing autochanger "loaded?
> drive 0" command.
> *messages
> 10-Jun 07:12 nmyservername-sd JobId 806: 3302 Autochanger "loaded? drive 0",
> result: nothing loaded.
> 10-Jun 07:12 nmyservername-sd JobId 806: Warning: mount.c:221 Open device
> "DLT-S4" (/dev/st0) Volume "Tape-0241" failed: ERR=dev.c:491 Unable to open
> device "DLT-S4" (/dev/st0): ERR=No medium found
> 
> But if I run the changer script from the command line:
> 
> /etc/bacula/scripts/mtx-changer /dev/sg3 load 1 /dev/st0 0
> 
> And then I run the backup just like before with the tape in the drive it
> runs fine.  But once I start trying to backup another client, it unloads the
> tape, moves it to slot 1 and then I get the error "3302 Autochanger "loaded?
> drive 0""
> 
> 
> 2010/6/9 Norberto Meijome <numardbsd AT gmail DOT com>
> 
>> 2010/6/10 bwellsnc <bwellsnc AT gmail DOT com>
>>
>> Here is what I have setup for my conf's.  I have my conf files in a conf.d
>>> directory. I added this to my bacula-dir.conf file:
>>>
>>>
>> Did you run all the suggested tests for mtx changer script , and did they
>> all pass?
>> _________________________
>> {Beto|Norberto|Numard} Meijome
>>
>> "I detest people who take short­cuts rather than do things right, because
>> they leave shit for the rest of us to clean up."
>>    PHK
>>
>>
>>
>>
>>
>> ------------------------------------------------------------------------------
>> ThinkGeek and WIRED's GeekDad team up for the Ultimate
>> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the
>> lucky parental unit.  See the prize list and enter to win:
>> http://p.sf.net/sfu/thinkgeek-promo
>> _______________________________________________
>> Bacula-users mailing list
>> Bacula-users AT lists.sourceforge DOT net
>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>>
>>
> 
> 
> 
> ------------------------------------------------------------------------------
> ThinkGeek and WIRED's GeekDad team up for the Ultimate 
> GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
> lucky parental unit.  See the prize list and enter to win: 
> http://p.sf.net/sfu/thinkgeek-promo
> 
> 
> 
> _______________________________________________
> Bacula-users mailing list
> Bacula-users AT lists.sourceforge DOT net
> https://lists.sourceforge.net/lists/listinfo/bacula-users


------------------------------------------------------------------------------
ThinkGeek and WIRED's GeekDad team up for the Ultimate 
GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the 
lucky parental unit.  See the prize list and enter to win: 
http://p.sf.net/sfu/thinkgeek-promo
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users