I'm running NW 7.4 on Windows platform and i would like to get media tracking information from NW, so how do i get the following information out of NW?
a) Barcode label of tape used, the retention period of that tape and from which pool?
b) When a particular tape is used for the first time and the last time it was used?
c) When a tape should be inserted back into tape library to be recycled and the number of time it was used?
d) When a tape will expire (content) and the location of each tape?
Just goto Networker Management Console
Click on Media --> Click on Volumes------- This is the location where you will get all your required information.
The provided link will give you the required arguments to be used.
Otherwise, if you need report to be extracted, then through GUI also you
can extract the same.
We're actually doing some of these, so maybe I can help here:
a. barcode label of tape used, retention periond and pool (assuming you want to list those back-ups since yesterday):
mminfo -av -q 'savetime>=yesterday' -r 'barcode,pool,volretent'
b. when a particular tape is used for the first time and the last time it was used (assuming volume name is VOLUME1):
mminfo -av -q 'volume=VOLUME1' -r 'volume,olabel,volaccess'
c. when a tape should be inserted back and the number of time it was used
- when to insert back will depend on your volume retention (see a.)
- number of times it was used might be difficult as NW tracks differently (please correct me if I'm wrong here), so you might want to try the parameters volaccess, labeled or mounts (see description on the reference guide mentioned in one of the post above).
d. when a tape will expire (content) and the location of each tape (assuming you mean saveset for contents):
mminfo -av -q 'volume=VOLUME1' -r 'name,ssretent,location'
Hope this helps.
All the information can be found from the command line requested here, as stated previously it just depends upon what exactly you need to report as for instance volaccess would change if the volume was mounted for any reason.
As for using this method to move tapes around from location to location you must remember that if there are full backups on a tape and they have dependent incremental backups NetWorker will not mark the tape or saveset as recyclable even though the retention period is passed (as they are still required to facilitate a restore). This is important as you may return tapes to the jukebox which cannot be used for backups and will not be automatically relabelled by NetWorker.
Also if these tapes were taken out of the jukebox and were not full they are valid to use - so backups will be appended to the volume and the volume retention increased. Best practice when exporting/importing tapes from the jukebox is to mark the volume as full during the process (this can also be automated via script or batch file as well as import/export).
I didn't see Roose's update before answering - I think we basically recommend the same stuff but just one comment for (d), be careful of using 'ssretent' as a means of judging when a tape will expire. The 'ssretent' value corresponds to the latest retention date of all instances of a saveset. Some of these instances (clones) could be on other volumes. It is the 'clretent' value that corresponds to the retention time of the instance of the saveset on one particular volume. The 'volretent' value is equal to the latest of all 'clretent' values for that volume.