cancel
Showing results for 
Search instead for 
Did you mean: 

Can't Expire Tape - Req Media ID was not found in NB

Dennis_SCWA
Level 3
I have a tape in a Volume Pool that I was able to determine is not being used. From the Media Contents report I found all the images on it are expired. I tried to manually expire the tape with bpexpdate but receive 'Requested media ID was not found in NB media database'.
 
How do I get the tape back into use?
 
Thanks
 
Dennis
1 ACCEPTED SOLUTION

Accepted Solutions

Stumpr2
Level 6


Dennis_SCWA wrote:
vmquery -m J206L1
=======================================
.
.
assigned:              ---

 
The absence of an assigned date meant, as shown by the vmquery command, that the data had already been deleted and that is why you kept getting "not found in NB media database."
 
 
 

View solution in original post

16 REPLIES 16

Stumpr2
Level 6
add a -host (hostname) to the bpexpdate command where the hostname is the name of the media server that did the backups.
 
 

Dennis_SCWA
Level 3
Thanks but I received the same result.
 
bpexpdate -m <media id> -d 0 -host <hostname>
 
 

Stumpr2
Level 6
How to manually remove a tape completely from NetBackup/Media Manager.
 
Try all of the steps. don't stop if one fails, keep going. if you still have problems then post the exact error messsages. I hope this helps.
 
 

netcat
Level 3
This will definately sort your headache, I have tried it several time especially on the "media not found in database annoyance"

vmquery -deassignbyid media_id pool_number status

To get the pool_number and status use the following command

vmquery -m media_id

say you got tape number FS1002 in a pool number 4 with status 0x0

the command would be

vmquery -deassignbyid FS1002 4 0x0

Dennis_SCWA
Level 3
I tried the vmquery command in the support doc 208420:
 
vmquery -deassignbyid <media id> <pool #> <status>
 
and received 'The act of unassigning volumes may lead to inconsistencies between the application media database and the volume database leading to the possibility to data loss. You must expire the media from and application interface.'
 
Any other ideas are welcome.

Nathan_Kippen
Level 6
Certified
Dennis,
 
What version of NB are you running? What OS?
 
Thanks
 
 
...in the meantime is the media frozen?
 
 

netcat
Level 3
Dennis

don't worry about the "The act of unassigning volumes may lead to ......' message.   This is just a caution.  In your case "because all the images are already expired"  the above command will work.

I'm afraid I already tried most of the commands to get rid of that problem but nothing works except the solution which I recommended to you above.

Regards

Colin_North
Level 6
Dennis,
If you're using Netbackup 6 then vmquery -deassignbyid no longer works you have to use bpexpdate to expire media.
 
See these technotes for more info:
 
Colin.

Dennis_SCWA
Level 3
I should have stated previously that it's NBU 5.1 on Solaris 9.
 
No, the tape is not frozen.
 
Thanks NetCat but no, it didn't work.
 
Colin, there is no nbeemmcmd command that I can see. I assume bpexpdate needs to be used because it's NBU 5.1. I'm on the edge of upgrading, finally. We're at the end of a SAP implementation and could not chance NBU failing.
 
This isn't the only tape in the robot that gives me this error - Two in total. I would normally toss the tape but I'd like to know how to resolve this in case it occurs again.
 
Dennis
 
 


Message Edited by Dennis_SCWA on 01-08-2008 06:40 AM

Colin_North
Level 6
Dennis,
Ignore my last post then, I didn't realise that you were using 5.1 - all the details in my post relate to NBU 6.0, which is where you'll find nbemmcmd. But bear those technotes in mind when you upgrade to 6.0 as you'll probably have media that give you this error if you're getting these errors in 5.1.
 
Colin.

Stumpr2
Level 6


Stumpr wrote:
How to manually remove a tape completely from NetBackup/Media Manager.
 
Try all of the steps. don't stop if one fails, keep going. if you still have problems then post the exact error messsages. I hope this helps.


Dennis,
Talk to me. Why were you not ble to follow the steps in the above post?
 

 

Dennis_SCWA
Level 3
Bob,
 
I ran through it again. Here is the result.
 
bpexpdate -ev <media id> -d 0
  - requested media id was not found in NB media database and/or MM volume database
 
bpmedia -unfreeze -ev <media id>
  - requested media id was not found in NB media database and/or MM volume database
 
bpmedia -unsuspend -ev <media id>
  - requested media id was not found in NB media database and/or MM volume database
 
vmquery -m J206L1
=======================================
media ID:              J206L1
media type:            1/2" cartridge tape 2 (14)
barcode:               FKJ206L1
media description:     Added by Media Manager
volume pool:           offsite (3)
robot type:            TLD - Tape Library DLT (8)
robot number:          0
robot slot:            1
robot control host:    chico
volume group:          00_000_TLD
vault name:            ---
vault sent date:       ---
vault return date:     ---
vault slot:            ---
vault session id:      ---
vault container id:    -
created:               Mon Aug 04 12:41:14 2003
assigned:              ---
last mounted:          Tue Jan 08 09:59:48 2008
first mount:           Mon Aug 04 12:52:13 2003
expiration date:       Wed Jan 07 06:10:00 2009
number of mounts:      206
max mounts allowed:    ---
========================================
vmquery -deassignbyid J206L1 3 0
=========================================
media ID:              J206L1
media type:            1/2" cartridge tape 2 (14)
barcode:               FKJ206L1
media description:     Added by Media Manager
volume pool:           offsite (3)
robot type:            TLD - Tape Library DLT (8)
robot number:          0
robot slot:            1
robot control host:    chico
volume group:          00_000_TLD
vault name:            ---
vault sent date:       ---
vault return date:     ---
vault slot:            ---
vault session id:      ---
vault container id:    -
created:               Mon Aug 04 12:41:14 2003
assigned:              ---
last mounted:          Tue Jan 08 09:59:48 2008
first mount:           Mon Aug 04 12:52:13 2003
expiration date:       Wed Jan 07 06:10:00 2009
number of mounts:      206
max mounts allowed:    ---
======================================================
CAUTION: The act of unassigning volumes may lead to inconsistencies
         between the application media database and volume database,
         leading to the possibility for data loss. You must expire the
         media from an application interface.

vmdelete -m J206L1
 - no output
 
vmquery -m <media id> 
  - Could not query by media ID J206L1: volume does not exist in database (35)
 
 
I overlooked the vmdelete command yesterday. It looks like that's what took care of the issue.
 
Thanks Bob.
 
While I've got your attention, what is the proper procedure to get the tape back into a specified Volume Pool?
 
Thanks again
 
Dennis 
 
 
 
 

Dennis_SCWA
Level 3
Bob,
 
I inventoried the robot. The tape, because of my barcode rules, put itself back into the correct Volume Pool.
 
Thanks for your help
 
Dennis Moore

netcat
Level 3
Dennis

I noticed that all of your commands got -h flag is missing this just ensures that you are running the commands on where your volume database host is.   I'm assuming you are running all these commands on where your volume catalog is.

By the way to change the tape to different pool use

vmchange -h volume_database_host -p pool_number -m media_id

or easy one is to use GUI on master server, get to the particular tape and right click to select the option change.

Dennis_SCWA
Level 3
NetCat,
 
Yes all the commands were run from the Media/Master server that hosts the Volume DB.
 
Thanks

Stumpr2
Level 6


Dennis_SCWA wrote:
vmquery -m J206L1
=======================================
.
.
assigned:              ---

 
The absence of an assigned date meant, as shown by the vmquery command, that the data had already been deleted and that is why you kept getting "not found in NB media database."