Bacula-users

Re: [Bacula-users] Intervention needed, asking for tape not in library

2013-07-03 13:15:49
Subject: Re: [Bacula-users] Intervention needed, asking for tape not in library
From: "Kevin B. Zimmerman" <kevin.zimmerman AT kitware DOT com>
To: bacula-users AT lists.sourceforge DOT net
Date: Wed, 03 Jul 2013 13:11:12 -0400
Looks like a winner; everything worked like I needed it to by following 
this set of steps.  Thanks to Uwe and Josh for comments and suggestions.

update slots enabled=0    (set all current tapes to disabled; could also 
specify slots=12-23 to do a subset of tapes, for example)
unmount
(remove magazine)
(insert new magazine)
update slots enabled=1        (set all new tapes to enabled; again, 
could specify slots=<range>)
mount                                    (when it asks for the 
autochanger slot, leave blank and just press enter)

Checking the volumes shows everything correctly marked as far as Enabled 
or not, and InChanger or not.  Bacula is now chugging along, taking 
tapes only from the set that's currently in the tape library.

Which brings me to my next question: does the documentation need to be 
fixed?  It indicates that when marked as InChanger, only those volumes 
will be used, but that doesn't appear to be the case.  I'm referencing 
the following:

http://www.bacula.org/en/dev-manual/main/main/Autochanger_Resource.html#SECTION002950000000000000000
"...Bacula will as a preference, use Volumes that it knows to be in the 
autochanger before accessing Volumes that are not in the autochanger. 
This prevents unneeded operator intervention."

Behavior doesn't quite match docs in this case, as it appears the 
InChanger flag is ignored in favor of the Enabled flag when deciding on 
which tape to request next, at least as far as Spool jobs are concerned 
(that's all I've really been using so far).


So, bug report?  Doc fix?  Both?

Thanks,

Kevin B. Zimmerman

On 07/02/2013 11:19 AM, Kevin B. Zimmerman wrote:
> Interesting. So if I'm reading the docs right 
> (http://www.bacula.org/manuals/en/console/console/Bacula_Console.html#SECTION00240000000000000000),
>  
> the process for swapping a magazine could change from this:
>
> unmount
> (remove magazine)
> (insert new magazine)
> update slots
> mount
>
> to this:
>
> update slots enabled=0
> unmount
> (remove magazine)
> (insert new magazine)
> update slots enabled=1
> mount
>
> Correct?
>
> Kevin B. Zimmerman
>
> On 07/02/2013 10:46 AM, Josh Fisher wrote:
>> On 7/2/2013 10:24 AM, Uwe Schuerkamp wrote:
>>> On Tue, Jul 02, 2013 at 10:07:16AM -0400, Kevin B. Zimmerman wrote:
>>>> Once I swap the old magazine out (following the instructions at
>>>> http://www.bacula.org/en/dev-manual/main/main/Autochanger_Resource.html#SECTION002950000000000000000),
>>>>  
>>>>
>>>> Bacula refuses to automatically use any tapes in the newly-inserted
>>>> magazine.  One of the tapes in the old magazine is in Append mode, and
>>>> it keeps asking for that tape despite it (and the other tapes from the
>>>> old magazine) not being marked as In Changer.  I can manually force
>>>> Bacula to unmount/update slots/mount and name a specific tape to use,
>>>> but once that tape fills up it goes back to asking for the tape 
>>>> from the
>>>> other magazine:
>>>>
>>> Hi Kevin,
>>>
>>> we're having the same "problem" although I am unsure if this isn't a
>>> feature of bacula trying to preserve data as long as possible.
>>>
>>> So far, I haven't found a way around bacula trying to mount removed
>>> volumes short of manually setting the removed volumes to status
>>> "archive".
>> You can enable/disable volumes using the 'enable' command in bconsole. A
>> short script can use bconsole to enable/disable all of the volumes on a
>> magazine. When a magazine is removed, use the script to disable the
>> magazine's volumes. Then when the magazine is attached use the script to
>> enable the volumes. This will cause Bacula to only try to use volumes
>> that are on attached magazines.
>>
>>> You can check the list archive for what I had hoped "update slots"
>>> would achieve, but it only covers certain aspects of what's needed
>>> (imho) when juggling around entire cartridges full of tapes.
>>>
>>> All the best, Uwe
>>>
>>>
>>> ------------------------------------------------------------------------------
>>>  
>>>
>>> This SF.net email is sponsored by Windows:
>>>
>>> Build for Windows Store.
>>>
>>> http://p.sf.net/sfu/windows-dev2dev
>>> _______________________________________________
>>> Bacula-users mailing list
>>> Bacula-users AT lists.sourceforge DOT net
>>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>>
>> ------------------------------------------------------------------------------
>>  
>>
>> This SF.net email is sponsored by Windows:
>>
>> Build for Windows Store.
>>
>> http://p.sf.net/sfu/windows-dev2dev
>> _______________________________________________
>> Bacula-users mailing list
>> Bacula-users AT lists.sourceforge DOT net
>> https://lists.sourceforge.net/lists/listinfo/bacula-users
>


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Bacula-users mailing list
Bacula-users AT lists.sourceforge DOT net
https://lists.sourceforge.net/lists/listinfo/bacula-users