Bacula-users

Re: [Bacula-users] Bacula BLOCKED waiting for mount

2015-08-03 16:57:23
Subject: Re: [Bacula-users] Bacula BLOCKED waiting for mount
From: Ana Emília M. Arruda <emiliaarruda AT gmail DOT com>
To: Bill Arlofski <waa-bacula AT revpol DOT com>
Date: Mon, 3 Aug 2015 17:52:45 -0300
Hello Michael,

I have been using Bacula tape volumes for 7 years. Since 3.X version up to now with 7.0.5 version. I had no problem with bacula recycling algorithm.
About your problem, the EPW680L3 ​volume should be used instead ​EPW681L3 volume if these two volumes had the same settings (volume retention, recycle flag, enabled, etc.) and both volumes had status full or used. I mean the same settings because if you change pool settings in your configuration files and do not apply them for the existent volumes, even if they are in the same pool, they will have different settings. If EPW681L3 volume, for some reason, was marked purged (manually or automatic), then Bacula would use this volume instead EPW680L3 volume. Lots of others situations could occurs here that caused Bacula to use EPW681L3 volume instead the EPW680L3 volume.

You can get the next volume that bacula would use for your backups with the "list nextvol" command from bconsole. This command returns only the first volume and if your backups spans over multiple tapes, this command will not be so helpful.

I´m attaching a script that I have been using for a few months and I think that it could help you to know previously the tape(s) that Bacula should use for your backups in a specific date/time.

IMHO, Bacula has a very stable recycling algorithm, and if things are well configured, it should work as expected.

Best regards,
Ana


On Mon, Aug 3, 2015 at 4:15 PM, Bill Arlofski <waa-bacula AT revpol DOT com> wrote:
On 08/03/2015 09:45 AM, Michael Schwager wrote:
> Kern,
> Thanks for the reply from The Man himself :-) .
>
> I ran update slots, and it's true that EPW681L3 is not in the library. But
> that's as I planned it it: Why would it go to EPW681L3 when EPW680L3 is right
> there in the library? It is in the same pool, it is as full as EPW681L3 once
> was, it's older than the file/job retention period, but somehow Bacula chose
> 681 instead of 680 which is what I was expecting.
>
> As a matter of fact, I marked all the eligible tapes as full: First I marked
> 681 full then Bacula chose 682. So I marked that one as full. Now 683 and
> beyond are younger than the file/job retention periods, so Bacula thinks it
> has no tapes. Meanwhile I'm pulling my hair out because I'm saying, "Bacula-
> 680 is *right there*!  Use it!" But no joy. Can I somehow mark a tape as usable?
>
> Under v. 5.x, I discovered that Bacula's tape usage algorithm went something
> like this: "Use an eligible tape from the library." I discovered (I think)
> that I could use any tape that met Bacula's rewritable criteria. Now, I don't
> know what the algorithm is. This means it will be difficult for me to choose
> the proper tape to put in the library. I need to know before the weekend
> starts so it doesn't hang up my backups.
>

Hi Michael,

You might try setting the enabled field to '0' for all volumes which are - or
should be - inaccessible (not in library), and therefore should not be
considered by Bacula as viable.

I had to implement this on my system a couple years back, and it has been
working fine ever since: http://revpol.com/node/146

I wrote that script to work out this same problem I was having when vchanger
drives were not in the drive caddy, and hence the file volumes on them were
not available.

You will surely have to adapt it, or probably just pick a few things from it
for your specific system because it is highly vchanger v0.8.6 centric. :)


Having said that, it is typically best to let Bacula manage what volumes it
wants, when it wants them, but in my situation, each hard drive I use with
vchanger has about 70 10GB volumes so I am not severely limiting Bacula, just
guiding it a little and giving it a nudge.  e.g.: I do not touch retention
times, nor do I manually force purges etc. :)

> Also, regarding my other question: How do I make Bacula fail hard if it
> doesn't find the media it needs?

I have used the various job "max ... time settings" for things like this in
the past.



Bill



--
Bill Arlofski
http://www.revpol.com/bacula
-- Not responsible for anything below this line --

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

Attachment: list_available_volumes.sh
Description: Bourne shell script

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