Forum Discussion

Stiva's avatar
Stiva
Level 4
9 years ago

Media Id mismatch

Hi All,   We are performing restore from old tape. Tape was used for backup with 2.3.4.5.6.7 media generation rule. Now it's showing with 1.2.3.4.5.6 media generation rule. We have recalled tap...
  • mph999's avatar
    9 years ago

    Find which slot it is in in the library - vmquery -m <media ID> or if that fails, use robtest s s command or library GUI / front panel.

    Delete the 'old' tape from NBU completely.

    Run a physical inventory on the tape:

    vmphyinv -rn 0 -rh womble -slot_list 1 -d hcart

    0 is the robot number

    rh is robot control host

    1 is the slot the tape is in in the library

    hcart the density 

    (Change these as required for your setup)

    This command should then inventory just that one slot, but instead of using the the media ID gen rule, it will actually read the header on the tape.  This way it assignes the old (and correct ) media ID against the barcode).

    This shold be the easiest way.

    Other option is to change the media ID rule so it will use 2/3/4/5/6/7 (the old setup) and run inventory.  This won't affect existing tapes but will add the new one correctly, then set the rule back.

    There is a lot to be said for:

    1.  Keeping media ID rules the same across libraries / environments.

    2.  Having a unique character in barcode ranges for each site/ environment

    Eg.

    AA1234L4  (Site A, library A)

    AB1234L4 (Site A, library B)

    BA1234L4 (Site B, library A) 

     

    ... and so on - this way providing you use 1:2:3:4:5:6 you won;t get buplicated barcodes or media ids, and can move media between sites etc with no issue.

    Note.  Appreciate (2) isn;t affecting you, but thought I would mention it.