Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how do I know what the next tape is?

Status
Not open for further replies.

cibermac

Programmer
Jun 2, 2003
7
US
I am runing under solaris and want to send and email to tell us what the next tape is to be used. But I can not find the correct switches. I was trying to use mminfo.

Any help is appricated?
 
I don't think you can find out. Networker picks tapes on its own. I don't think you will be able to figure this out.

Now, why do you want to figure this out?

Also NW will post a message stating which tape it wants mount after it has filled up the last one also.

John7
 
For off site rotation I mark the last nights tape as full and eject it. I then send and email to our tape librarian. I got burned when the librarian had not loade the correct tapes. THe job staled because it was waitng for a tape that was not in the system.

So, I want to query the system to find out what then next avilable tape is, email it and help prevent this from happening again.

Another piece of this could be to send out a notification if a tape in not loaded in thirty minutes. I would then need to know how to force a mount of the next avilable tape from the command line.
 
NetWorker's concept is to use a pool, not a specific media.
Why? - Because the media you want to use could just be used
already (for example by a recovery) and the backup just would have to wait in such situation.
NW tries to fill older tapes first but only if this is possible with respect to the current situation.
 
The only situation where i see that this will work is a
recovbery, but not for backups.
 
What I have done is run mminfo with various switches to produce the following report.
mminfo -a -r 'state,volume,%used,volretent,space,location,mounts,recycled'

volume (%) expires location mounts rcyc
CQ6740L1 full 06/30/03 42 7
CQ6741L1 full 06/29/03 27 7
CQ6742L1 full 07/01/03 19 7
CQ6743L1 full 06/28/03 17 6
CQ6744L1 full 06/27/03 tape0 18 6
CQ6745L1 24% 06/26/03 19 6
CQ6746L1 full 07/07/03 21 7
E CQ6747L1 full expired tape0 15 6
CQ6748L1 full 06/26/03 tape0 17 6

This may not have been what I wanted but it is working for me.

Thank you for the responses.

Charles Berman
 
This works but of course only for media that has been written to. If you so not have any save set stored, it must fail, because there simply exists no save set entry in the
media database. Hence the Report will not list these tapes.
 
There is an order to tape selection, something like:
1: Is there a tape with space mounted on a drive for this pool?
2: Is there a tape with free space for this pool?
3:.....

Assuming you are using a jukebox/silo, you can either
a) make sure you only have one tape in for the relevant pool, you can check this with nsrjb | grep or nsrjb | find "...." (on Windows).

b) check you have at least one tape, as in a) and then mount the tape onto a deck. That way, it will always be the one selected.

 
As far as i know, the selection sequence works as follows:

1. NW chooses an appendable tape from the same pool
2. NW chooses a reyclable tape from the same pool
3. NW chooses a recyclable tape from another pool
This will only work if you have checked the pool's
options "recycle from/to another pool"
4. NW chooses a blank tape
This requires Auto Media Management to be active

This sequence works - so far so good. But you cannot
predict a specific tape from a pool.

As the script shows, you may find out which tapes are
appendable and most likely will be picked. However, if
the 'next' tape is used for a recovery while you also want
to write, then NW will simply use another one that he can
proceed with the backup.

 
If you only have one tape deck, then if an appendable tape is loaded, that is always first choice.
The other way is to ensure you only ever have one appendable tape in the jukebox.
 
mminfo also has a field called 'next', which gives each volume a number. It looks as if this number indicates which volume will be the next to be loaded.
I have not tested this, but it might help
 
mminfo can only help on existing backups as there would be
no info available before you have backed up. I think "next"
refers to the next media if the save savet uses more than
one.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top