Amanda-Users

Re: Rename tape labels?

2003-10-31 17:12:37
Subject: Re: Rename tape labels?
From: Eric Siegerman <erics AT telepres DOT com>
To: amanda-users AT amanda DOT org
Date: Fri, 31 Oct 2003 17:07:37 -0500
On Fri, Oct 31, 2003 at 01:25:12PM +0530, Rohit wrote:
> Is there anyway I can change tape label names after I'm well into amanda 
> dumpcycle? I currently have TLS-Set-1-01.. Set-1-02.. Set-2-01 and so on. 
> I want to get rid of this set concept from the label.

This is untested; treat it with caution...

 1. To begin the process, change the "labelstr" regexp in
    amanda.conf so that both the old and new label styles are
    recognized.

 2. For the next tapecycle's worth of dumps, you'll have a mix of
    old- and new-style labels.  Each day that a tape with an
    old-style label comes up to be reused:
     a. Do "amrmtape <config> <old-label>"

     b. Relabel the tape with a new-style label.  Amanda will
        consider it to be a "new tape", but that's ok.
    
 3. After all of the old-style tapes have been relabelled, change
    "labelstr" again, to only accept the new style of labels


WARNINGS:
  - DO NOT do (2) all at once for all of the tapes; you'll
    clobber your backups.  Make sure you do those steps, for each
    tape, just before Amanda would have overwritten that tape
    anyway.

  - If you're still on your first tapecycle, i.e. you're still
    adding new tapes one at a time, you'll have to finish adding
    in your new tapes before you can even begin step (2).

  - During this process, you're circumventing all (or most) of
    Amanda's protections against clobbering the wrong tape.  So
    be careful!

--

|  | /\
|-_|/  >   Eric Siegerman, Toronto, Ont.        erics AT telepres DOT com
|  |  /
When I came back around from the dark side, there in front of me would
be the landing area where the crew was, and the Earth, all in the view
of my window. I couldn't help but think that there in front of me was
all of humanity, except me.
        - Michael Collins, Apollo 11 Command Module Pilot


<Prev in Thread] Current Thread [Next in Thread>