On Tue, Feb 04, 2014 at 11:18:24AM -0500, Michael Stauffer wrote:
> Thanks Jon. What I'm unsure about is this part from the amanda.conf page,
> about autolabel param:
> 
> *"autolabel* *string* [*any*] [*other-config*] [*non-amanda*] [
> *volume-error*] [*empty*]
> 
> Default: not set. When set, this directive will cause Amanda to
> automatically write an Amanda tape label to most volume she encounters.
> This option is DANGEROUS because when set, Amanda may erase near-failing
> tapes or tapes accidentally loaded in the wrong slot."
> 
> What does "encounters" mean here? If amanda comes across a tape during an
> operations other than 'amlabel', will a label be written if it matches any
> of the cases defined by this param (presumably by amanda calling amlabel)?
> Or does this only apply to when the operator manually runs 'amlabel'?
> 
> If I only define autolabel like so:
> 
> autolabel "%b-%c"
> 
> is it safe to assume Amanda will never label anything on her own?
> 

This is based on my reading as I've always manually labelled my tapes.

"autolabel" seems quite protective and thus has options to override
the protections.  It will not autolabel empty tapes, amanda tapes
from other configs, tapes with non-amanda data on them, and
unreadable tapes.

I think that eliminates all tapes except those already labelled with
for the current config.  There I can think of 4 conditions:

  In Tapelist?    Marked       Active      Expected Autolabel Action
      yes        no-reuse        NA        skip
      yes         reuse         yes        skip   (too recent)
      yes         reuse          no        skip   (use for the dump)
       no          NA            NA         ?

The only one I can see being autolabelled is the last.

It seems to me that you have to tell autolabel under what conditions
it is allowed to autolabel.  Then the responsibility is yours ensure
no valuable tape meeting those conditions is ever encountered by amdump.

HTH
Jon

> On Mon, Feb 3, 2014 at 7:18 PM, Jon LaBadie <[email protected]> wrote:
> 
> > On Mon, Feb 03, 2014 at 06:47:32PM -0500, Michael Stauffer wrote:
> > > Hi,
> > >
> > > I'm hoping to use autolabel like this:
> > >
> > >   autolabel "$b-$c-config-name"
> > >
> > > so that I can do tape labeling like this to easily label new tapes:
> > >
> > >   amlabel config-name slot N
> > >
> > > With my definition of autolabel above, will amanda *never* automatically
> > > label a tape that it encounters and is unsure of? This is way I infer
> > from
> > > the autolabel discussion in amanda.conf man page, but it's not stated
> > > explicitly. I'd like to play it safe (at least for now) and always
> > manually
> > > label new tapes.
> >
> > It is explicit on the amlabel manpage:
> >
> >   "As a precaution, amlabel will not write a label if the volume
> >    already contains an active label or if the label specified is on an
> >    active tape.  The [-f] (force) flag bypasses these verifications."
> >
> > jl
> > --
> > Jon H. LaBadie                 [email protected]
> >  11226 South Shore Rd.          (703) 787-0688 (H)
> >  Reston, VA  20190              (609) 477-8330 (C)
> >
>>> End of included message <<<

-- 
Jon H. LaBadie                 [email protected]
 11226 South Shore Rd.          (703) 787-0688 (H)
 Reston, VA  20190              (609) 477-8330 (C)

Reply via email to