Hi,

08.11.2007 22:05,, Craig White wrote::
> On Fri, 2007-11-02 at 23:05 +0100, Arno Lehmann wrote:
>> Hi,
>>
>> 02.11.2007 21:48,, Craig White wrote::
>>> On Fri, 2007-11-02 at 21:38 +0100, Arno Lehmann wrote:
>>>> Hi,
>>>>
>>>> 02.11.2007 21:26,, Craig White wrote::
>>>>> On Fri, 2007-11-02 at 15:08 -0400, John Drescher wrote:
>>>>>> On 11/2/07, Craig White <[EMAIL PROTECTED]> wrote:
>>>>>>> I am a bit befuddled.
>>>>>>>
>>>>>>> I have a 'Full' backup which consists of 4 jobs but it extends onto 2
>>>>>>> tapes.
>>>>>>>
>>>>>>> the Pool permits 4 jobs
>>>>>>>   Maximum Volume Jobs = 4
>>>>>>>   Volume Retention = 19d
>>>>>>>   Volume Use Duration = 4d
>>>>>>>
>>>>>> I believe "Maximum Volume Jobs" here will allow at most 4 jobs to a
>>>>>> single volume and since there are only 2 jobs written to the last
>>>>>> volume it can hold 2 more.
>>>>> ----
>>>>> I get that. I can't change the number to 2 because then it would stop
>>>>> after the second job and force me into a new tape leaving half the first
>>>>> tape filled and not enough room on second tape to complete the next 2
>>>>> jobs (the second being a standard BackupCatalog job).
>>>>>
>>>>> I find it hard to believe that I am the only one who is spanning tapes
>>>>> on a single Pool and wanting to have the last tape marked 'Used' instead
>>>>> of 'Append'
>>>> True... but as it is, many users try to avoid problems they might run 
>>>> into when jobs are added, or don't run for whatever reason, so they 
>>>> don't limit the volume use by the number of jobs, but rather by the 
>>>> time it can be used after an initial write ;-)
>>>>
>>>> So my suggestion is to use "Volume Use Duration" instead of the job 
>>>> limit. Depending on your needs, limiting by size might also be useful 
>>>> - "Maximum Volume Bytes" is the corresponding option.
>>>>
>>>> Does that help?
>>> ----
>>> in that I have set (as noted above) Volume Use Duration to 4d, if it
>>> marks the set as 'Used' on Tuesday (Friday, Saturday, Sunday, Monday)
>>> constituting the 4 days and then Bacula respects the 'Volume Retention',
>>> I am good to go.
>> In my experience, Bacula does handle retention periods correctly.
>>
>>> As you might expect, I am concerned that the next usage of ThursdayPool,
>>> that it asks for this Volume because it is still marked 'Append' and I
>>> would want it to ultimately ask for the one of the ThursdayPool volumes
>>> whose 'Volume Retention' has expired.
>> Let's say your volume is marked as used on Thursday, and it's been 
>> last written to on Thursday, too, and you've got a retention time of 
>> six days, that volume could be recycled next weeks Thursday.
>>
>> If you swapped the volumes and updated the catalog accordingly, Bacula 
>> will prefer volumes in the autochanger, i.e. when it needs a Thursday 
>> volume, it will prune, recycle, and use that volume automatically.
>>
>> I think this is what you need.
> ----
> OK - here it is the next Thursday.
> 
> Tape with 2 jobs from last Friday is not now, nor was ever marked 'Used'
> - it is still marked 'Append'
> 
> # bconsole
> Connecting to Director linserv1.mullenpr.com:9101
> 1000 OK: LINSERV1 Version: 2.2.5 (09 October 2007)
> Enter a period to cancel a command.
> *list media pool=ThursdayPool
> Automatically selected Catalog: MyCatalog
> Using Catalog "MyCatalog"
> +---------+-------------------+-----------+---------+-----------------+----------+--------------+---------+------+-----------+-----------+---------------------+
> | MediaId | VolumeName        | VolStatus | Enabled | VolBytes        |
> VolFiles | VolRetention | Recycle | Slot | InChanger | MediaType |
> LastWritten         |
> +---------+-------------------+-----------+---------+-----------------+----------+--------------+---------+------+-----------+-----------+---------------------+
> |      10 | 1_Friday_Week_3   | Append    |       1 |  39,130,656,768 |
> 41 |    1,641,600 |       1 |    0 |         0 | LTO       | 2007-11-02
> 10:50:33 |
> |      11 | 1_Thursday_Week_3 | Full      |       1 | 130,561,191,936 |
> 132 |    1,641,600 |       1 |    0 |         0 | LTO       | 2007-11-02
> 03:30:19 |
> |      16 | 1_Friday_Week_1   | Append    |       1 |          64,512 |
> 0 |    1,641,600 |       1 |    0 |         0 | LTO       | 0000-00-00
> 00:00:00 |
> +---------+-------------------+-----------+---------+-----------------+----------+--------------+---------+------+-----------+-----------+---------------------+
> 
> Pool {
>   Name = ThursdayPool
>   Pool Type = Backup
>   Recycle = yes
>   AutoPrune = yes
>   Volume Retention = 19d
>   Volume Use Duration = 4d
>   Maximum Volume Jobs = 4
> }
> 
> Since 1_Friday_Week_3 was last written 2007-11-02 and more than 4d have
> passed, it's pretty clear that if Bacula was going to mark that volume
> 'Used', it would have done so by now. It hasn't

It will only be marked "Used" when Bacula looks for a usable volume 
and considers it. Bacula does not have an internal marker to indicate 
that, on 2007-11-06 (or whatever the result of FirstWritten+4d would 
be) this tape has to marked as used. Instead, only when considering 
this as a volume to use, it encounters the state of 
(FirstWritten+VolUseDuration<nom() if that makes sense...) and sets 
the status accordingly.

> 
> Short of marking the volume 'Used' manually, how can I ensure that the
> Volume is properly prevented from re-use during the 19 days of Volume
> Retention?

Try it - I'm fairly sure Bacula will not add to this volume. If I'm 
wrong I'll have to re-think what I implemented some times now :-)

Arno

> Craig
> 
> 
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Splunk Inc.
> Still grepping through log files to find problems?  Stop.
> Now Search log events and configuration files using AJAX and a browser.
> Download your FREE copy of Splunk now >> http://get.splunk.com/
> _______________________________________________
> Bacula-users mailing list
> Bacula-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/bacula-users
> 

-- 
Arno Lehmann
IT-Service Lehmann
www.its-lehmann.de

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems?  Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Bacula-users mailing list
Bacula-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/bacula-users

Reply via email to