what is the use of Media id in NETBACKUP when we have barcode?
YOu can review the following documents
You can get the information from here.
(Note: if you get the satisfy answer then mark this as solution)
The reason they are shown in the gui.......
if the barcode comes off or gets switched. When a tape is loaded netbackup compares the barcode that the library says it put in the drive to the label written on the tape( if it is first use netbackup writes it).
if the barcode and the written label do not match... netbackup will freeze the tape and not use it.
reason is that netbackup wants to make sure that it does not overwirte a good tape my mistake.
WHAT THIS MEANS?
"WHAT THIS MEANS?"
Seems you have answered your own question:
"reason is that netbackup wants to make sure that it does not overwirte a good tape my mistake."
Supporting Storage Foundation and VCS on Unix and Windows as well as NetBackup on Unix and Windows
Handy NBU Links
So a volume gets a media ID once it is written?
Fresh new media id wont have a media id until something has written on it?
No, a volume gets a media id written on the beginning of the tape when it is labelled - it does not have to contain data at this time.
a new tape does not have anything written to it.
When NB calls the tape for the first time the barcode is read and that same number is written to the tape as the Media id. The NB will try writing the backups to the tape.
now the backup could fail so no data on tape
or you could just bplabel the tape putting the media id on it without doing a backup
either way it gets an ID (on standalone tape drives you have to label the tape as it was not read by a barcode reader - other wise it gets a generic media id like A00000)
now if a label falls off and a different one gets put on
or a tape was labeled in standalone then gets a barcode
you now have a tape where the barcode is one number and the media id written on the tape is different.
when the tape is next loaded either for a backup or a restore - the two are compared - if they do not match NB will freeze the tape.
This is because NB does not know if you put a new barcode on the tape on purpose or by mistake so it does not want to overwrite what could be a valid backup tape.
this is also why we have the bplabel - if we do change the barcode on a tape we can force a label on it - where it will but the new media id on the tape giving it the same id as the barcode - then you can write to it.
I don't have to know how to spell....I work on Unix.
NetBackup 7.0.1 - AIX & Windows
So when we inventory media ,media id generates on it based on the barcode.
Media label can be done by invenory or manually.
Yes, the media id is generated based on the 'media id generation rule' if set (otherwise it takes the first 6 characters of the barcode (default)).
The inventory doesn't label the tapes, this is done either manually as you suggest, or when NBU uses the tape for a backup, if it finds the tape 'blank; (no header' it will label it).
so what if i insert a brand new tape.Then?what afte inventory?
I answered this question in the post you marked as the solution (thank you).
An inventory does nothing with labels, all it does is gets the library to tell NBU where the tapes are (that is, in what slots the tapes are in). NBU enters this information into the 'volume databse'.
The tape remains 100% blank - nothing is on it at all. If the tape is not used, it will never be labelled (unless you do it manually).
The NBU volume label is only written to this tape when :
1. The tape is written to in a backup, or used for a duplication
2, If you maually label it
That is it, it is no more complex than that.
You do not really need to worry about this, just leave it to NBU, it will do it all. If theer are issues, then ask for help.
ok so if a brand new tape has not gone into a tape drive for writing do it will remain unlabelled?
You might manually label it, but of not, it will remain unlabelled until it is used.
so that new tape after inventory will go into netbackup pool and in the media tab,we will only see the barcode mentioned and media id blank.
I think you will still see the media ID, just that it has not been written to the beginning of the tape until it is used.
I am confused!!!!!
When you inventory a tape, the tape will appear in the netbackup GUI with the media id and the barcode.
All an inventory does is put the details of the tapes in the library in to the volume database. Is does not do any labelling.
At this time, the tape is NOT labelled.
The tape is ony labelled (the media id is written to the beginning of the tape) when it is used for the backup/ duplication, or, if you do it manually.
If this comment is helpfull, Don't forget to give a "Thumbs Up" or mark as "Solution"
Think of it this way.
Createing the media id is related to the barcode - hence why the 'Media id generation rules" is set in the robot inventory screen (advanced options).
Here is a tape from my library (this is from the vmquery command)
so initially on a media we have only barcode.
and label is generated when something is written on it?
we can see barcode from our naked eye but not media id?
Yes, that is correct.
The media id along with the barcode will be seen in NBU gui, but on the tape, the media id is only written to it once it is used.