cancel
Showing results for 
Search instead for 
Did you mean: 

Media Id mismatch

Stiva
Level 4

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 tape from offsite and it's in library but it's showing with new media rule and in scratchpool. but when I checked the tape in media tab I can see two different tapes one with old rule with data within it and with new rule which is scratch now.

Could you please help us to resolve this issue as our restore is not working due to this issue.

No change in environment.

Netbackup version 7.1.

 

Thanks,

1 ACCEPTED SOLUTION

Accepted Solutions

mph999
Level 6
Employee Accredited

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.

View solution in original post

4 REPLIES 4

Marianne
Level 6
Partner    VIP    Accredited Certified
I am surprised that NBU would add the media as new when there is another media-id with the same barcode. Please show us output of this command for the 'old' and 'new' media-id : vmquery -m ( media-id ) We should be able to fix this with a couple of vm commands.

mph999
Level 6
Employee Accredited

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.

Stiva
Level 4

Thanks for suggestions.

We had to change the media generation rule as per the old setup to work the restore. We deleted media from the Backup console and performed inventory again. It was properly recognised this time.

After completion of restore we changed the rule as it is.

 

Marianne
Level 6
Partner    VIP    Accredited Certified

Next time you need to restore from an old tape, you should be able to use vmadd or vmchange.

Some examples from previous posts:

https://www-secure.symantec.com/connect/forums/cant-import-tape-how-change-barcode#comment-10917051 

https://www-secure.symantec.com/connect/forums/media-id-not-unique-database-34-1 

https://www-secure.symantec.com/connect/forums/not-able-import-lto4-tape-using-lto5-drive

(There are more discussions like these, but you get the picture...)