08-24-2018 08:35 AM
Hi all,
I see that there are lots of post on using bpexpdate to changing media expiration using the following command:
bpexpdate -m <media ID> -d <DATE> -host <media server> -force
This work great for most of the media we have assigned, unfortunately we are also seeing results with the following error:
requested media id is not assigned to this host in the EMM database
the -host option should fix this, but it is not working for us.
Has anyone else got this issue and fixed it.
Thanks in advance
Dave
08-24-2018 09:23 AM
08-27-2018 12:05 AM
Any chance you are using SLPs in the environment?
And that these media-ids are under SLP control?
08-27-2018 07:42 AM
Are you sure the media is active and not available?
08-28-2018 12:50 AM
We don't have any SLP Policies
08-28-2018 12:55 AM
The media status for some is active, but we also have status of Full, Full MPX and imported
08-28-2018 01:00 AM
nbemmcmd -listmedia -mediaid 0211L4
NBEMMCMD, Version: 7.6.0.3
====================================================================
Media GUID: 7fb47176-cbcd-429c-a6fc-f0e5007fa270
Media ID: 0211L4
Partner: -
Media Type: HCART3
Volume Group: ---
Application: Netbackup
Media Flags: 1
Description: Added by Media Manager
Barcode: QT0211L4
Partner Barcode: --------
Last Write Host: aijyms03.ai.local
Created: 23/10/2014 14:21
Time Assigned: 27/10/2014 19:31
First Mount: 27/10/2014 19:32
Last Mount: 05/06/2015 23:58
Volume Expiration: -
Data Expiration: INFINITY
Last Written: 06/06/2015 02:58
Last Read: -
Robot Type: NONE
Robot Control Host: -
Robot Number: -
Slot: -
Side/Face: -
Cleanings Remaining: -
Number of Mounts: 9
Maximum Mounts Allowed: 20000
Media Status:
Kilobytes: 1060539720
Images: 33
Valid Images: 1
Retention Period: 8
Number of Restores: 0
Optical Header Size Bytes: 1024
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: aijyms06
Server Group: NO_SHARING_GROUP
Upgrade Conflicts Flag:
Pool Number: 9
Volume Pool: ENCR_EOM
Previous Pool Name: Scratch_Pool
Vault Flags: -
Vault Container: -
Vault Name: -
Vault Slot: -
Session ID: -
Date Vaulted: -
Return Date: -
Media on Hold: 0
====================================================================
Command completed successfully.
08-28-2018 01:02 AM
08-28-2018 03:19 AM
Here is an example of one failing:-
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpexpdate -m 0211L4 -d 14/05/2025
Are you SURE you want to change (null)
to expire on 14/05/2025 00:00:00 y/n (n)? y
requested media id is not assigned to this host in the EMM database
Here is one that works ok:-
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpexpdate -m 5902L4 -d 02/01/2028
Are you SURE you want to change (null)
to expire on 02/01/2028 00:00:00 y/n (n)? y
08-28-2018 03:28 AM
So 'Last Write Host' for 0211L4 is media server aijyms03.ai.local.
What happens if you add '-host aijyms03.ai.local' ?
08-28-2018 04:23 AM
We get the same error after adding -host aijyms03.ai.local to the command e.g.
bpexpdate -m 0211L4 -d 14/05/2025 -host aijyms03.ai.local
08-28-2018 04:52 AM
Wait....
Maybe the error message is a 'red herring'.
NBU expects -d value in this format:
mm/dd/yy
Please try 05/14/2025?
08-28-2018 05:07 AM
Good try, but...
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpexpdate -m 0211L4 -d 05/14/2025 -host aijyms03.ai.local
Invalid start date: 05/14/2025
08-28-2018 05:15 AM
Okay, so, the date format has been changed in your environment.
The only logical conclusion now is that there is some inconsistency in your NBU databases.
Is this media server still actively being used in the environment?
Have you tried to run 'images on media' report?
bpimmedia -mediaid 0211L4 -U
Since there seems to be only one valid image left on the tape, there shouldn't be lots of output.
Please show us output.
08-28-2018 05:27 AM
Hi Marianne,
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpimmedia -mediaid 0211L4 -U
--------------------------------------------------------------------------------
Backup-ID: AIJYMS01_1402787667
Policy: AIJYMS01
Schedule Type: FULL
Retention Level 8
Number of Files: 159761
Compression: Y
Encryption: N
Image Type: Imported
Primary Copy: 2
Expires: INFINITY
Image on Hold: 0
Indexing Status: 0
Copy Number: 2
Fragment Number: 1
Fragment Size (KB): 27969529
Media Type: RMed
Density: hcart3
File Number: 1
Offset: 2
Host: aijyms02.ai.local
Device Written On: 0
MPX: N
Expires: INFINITY
Retention Level: 8
MediaID: 0211L4
Copy on Hold: 0
08-28-2018 05:31 AM
Okay, media server here is listed as aijyms02.ai.local.
Is this media server alive and well in NBU environment?
08-28-2018 06:13 AM
Yes we have 1 master , 4 media servers and all are live and well.
08-28-2018 07:08 AM - edited 08-28-2018 07:10 AM
I see that you are still on NBU 7.6.
So, I cannot ask you to log a call with Veritas Support to investigate what the issue is here.
nbemmcmd shows Last write host as aijyms03.ai.local
but this remaining image was written by media server Host: aijyms02.ai.local.
Are you using Media sharing and Multiple Retentions on media?
'last image' written by aijyms03 already expired?
Try to use -host as aijyms02.ai.local , or else try to change retention on the image-id:
bpexpdate -d <date> -backupid AIJYMS01_1402787667
08-28-2018 07:27 AM
Tried with aijyms02.ai.local and got the same result.
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpexpdate -d 06/06/2020 -backupid AIJYMS01_1402787667
to expire on 06/06/2020 00:00:00
No changes made.
Also tried:-
D:\Program Files\Veritas\NetBackup\bin\admincmd>bpexpdate -recalculate -ret 10 -backupid AIJYMS01_1402787667
Are you SURE you want to recalculate expiration dates on all images
that meet the following criteria:
backupid AIJYMS01_1402787667
retention will be changed to 10(10 years)
Continue?(y/n)y
requested media id is not assigned to this host in the EMM database
08-28-2018 08:03 AM