cancel
Showing results for 
Search instead for 
Did you mean: 

requested media id is not assigned to this host in the EMM database

Moley
Level 3

Hi,

I am having an issue where I can't delete a tape from Netbackup from the command line. You can delete OK from the GUI.

I have a bulk load of tapes I want to delete from the command line.

On the master sever (Netbackup 6.5.6)

# bpexpdate -m 007665 -d 0 -force
requested media id is not assigned to this host in the EMM database

# nbemmcmd -allrecords -listmedia -mediaid 007665

NBEMMCMD, Version:6.5.6
====================================================================
Media GUID:                     6cc94c32-ce1a-13d0-805d-fd2497c6c647
Media ID:                       007665                             
Partner:                        -                                  
Media Type:                     HCART3                             
Volume Group:                   ---                                
Application:                    Netbackup                          
Media Flags:                    1                                  
Description:                    ----                               
Barcode:                        007665                             
Partner Barcode:                --------                           
Last Write Host:                NONE                               
Created:                        12/29/2009 13:43                   
Time Assigned:                  -                                  
First Mount:                    01/07/2010 02:47                   
Last Mount:                     09/16/2010 10:38                   
Volume Expiration:              -                                  
Data Expiration:                -                                  
Last Written:                   01/06/2010 04:19                   
Last Read:                      09/16/2010 10:38                   
Robot Type:                     NONE                               
Robot Control Host:             -                                  
Robot Number:                   -                                  
Slot:                           -                                  
Side/Face:                      -                                  
Cleanings Remaining:            -                                  
Number of Mounts:               4                                  
Maximum Mounts Allowed:         0                                  
Media Status:                   ACTIVE                             
Kilobytes:                      0                                  
Images:                         0                                  
Valid Images:                   0                                  
Retention Period:               -                                  
Number of Restores:             3                                  
Optical Header Size Bytes:      0                                  
Optical Sector Size Bytes:      0                                  
Optical Partition Size Bytes:   0                                  
Last Header Offset:             0                                  
Adamm Guid:                     00000000-0000-0000-0000-000000000000
Rsm Guid:                       00000000-0000-0000-0000-000000000000
Origin Host:                    NONE                               
Master Host:                    sblxpnma01.ad.bgep.co.uk           
Server Group:                                                      
Upgrade Conflicts Flag:                                            
Pool Number:                    5                                  
Volume Pool:                    scratch                            
Previous Pool Name:             Eddie_tld1_LTO3                    
Vault Flags:                    -                                  
Vault Container:                -                                  
Vault Name:                     Eddie_overspill                    
Vault Slot:                     -                                  
Session ID:                     69                                 
Date Vaulted:                   -                                  
Return Date:                    -                                  
====================================================================
Command completed successfully.

Anybody shed any light?

Thanks,

Paul

1 ACCEPTED SOLUTION

Accepted Solutions

Marianne
Level 6
Partner    VIP    Accredited Certified

The message is 100% correct: "requested media id is not assigned ..."

There is nothing to expire - bpexpdate expires images associated with media-id. Have another look at the output:

Last Write Host:                NONE                               
Created:                        12/29/2009 13:43                   
Time Assigned:                  -                                  
First Mount:                    01/07/2010 02:47                   
Last Mount:                     09/16/2010 10:38                   
Volume Expiration:              -                                  
Data Expiration:                -                                 

 

If you want to delete the media-id from EMM database, use vmdelete:

Usage: vmdelete [-h <EMM_server> | <volume_database_host>]
           [-m <media_id> | -v <volume_group>]

View solution in original post

4 REPLIES 4

Yogesh9881
Level 6
Accredited

which media server is  owner of this tape ? ??

run below command

nbemmcmd -listmedia -mediaid 007665 | grep -i Media

bpexpdate -m 007665 -d 0 -h <media server>

bpexpdate -m 007665 -d 0 -h sblxpnma01.ad.bgep.co.uk ( i presumes that master is media owner)

watsons
Level 6

bpexpdate command does not delete a media for you, it simply means expiring the image from the media.

I didn't see your attempt to try deleting media from CLI.

You may want to try the following command, but you need to be VERY SURE that your media DOES NOT contain any valid image (expired) and is good for deletion from Netbackup.  This will be like removing the media from the GUI.

# nbemmcmd -deletemedia -mediaid 007665

Marianne
Level 6
Partner    VIP    Accredited Certified

The message is 100% correct: "requested media id is not assigned ..."

There is nothing to expire - bpexpdate expires images associated with media-id. Have another look at the output:

Last Write Host:                NONE                               
Created:                        12/29/2009 13:43                   
Time Assigned:                  -                                  
First Mount:                    01/07/2010 02:47                   
Last Mount:                     09/16/2010 10:38                   
Volume Expiration:              -                                  
Data Expiration:                -                                 

 

If you want to delete the media-id from EMM database, use vmdelete:

Usage: vmdelete [-h <EMM_server> | <volume_database_host>]
           [-m <media_id> | -v <volume_group>]

Moley
Level 3

Ah yeah sorry.

I was totally confused. I want to delete the tape, not expire the image.

Thanks for the quick responses.

Regards,

Paul