Video Screencast Help

Media Expiration Dates

Created: 13 Feb 2013 • Updated: 30 Apr 2013 | 10 comments
This issue has been solved. See solution.

Its the novice again. In my policies I have set the weekly schedule having a retention set to infinity (level 5) - FIGURE 1.

I use vault to expire the images. I have set the retention level on tape to 5 Weeks (level 2) - FIGURE 2.

I started my weekly (full) backup on Jan 18. When I click on the Media under Media and Device Management in the NetBackup Administration Console, the Time Assigned dates do not correspond to the Date Expiration dates taking into account the 5 weeks retention period - FIGURE 3

How does NetBackup calculate the 5 week period? Please see attached screen shots. Thanks

Comments 10 CommentsJump to latest comment

mph999's picture

If I have understood your question correctly ...

The assign time on a tape, is the date it is first used for a backup.  Once this is 'set' it should never change, until the tape expires.

In more detail.

A tape that is showing in the NBU gui, MUST be in the volume DB.

A tape is only 'moved' into the media database when it is first assigned for backups, or in other words, has data written to it.

Once the tape is expired (backups expire) it is remove from the media DB (will no longer show in bpmedialist command for example) and the assign time is 'removed', until such a time that it is reused.

vmquery commands for example works on the volume DB (is the tape known to NBU)

bpmedialist command works on the media DB (are there images on the tape).

Hope this helps,


Regards,  Martin
Setting Logs in NetBackup:
Marianne's picture

Please show us output of this command for one of the tapes that you've highlighted:

nbemmcmd -listmedia -mediaid <media-id>

If we look at your vault profile, duplicated source tapes will expire within 168 hours.
So, what we see here is duplicated tapes (still showing retention level 5 (which you have customized to infinity) that will expire within 168 hours after duplication.

As per Martin's excellent post, the Assign Time was the first time that original backup was written - nothing to do with your 5 week retention level.
The tapes used for duplication should show retention level 2 (5 weeks) with relevant expiration date.

Supporting Storage Foundation and VCS on Unix and Windows as well as NetBackup on Unix and Windows
Handy NBU Links

RamNagalla's picture

if the tapes are using for duplication with retenciton of 5 weeks, they should show retention level 2 but they are showing retenction level 5

along with above nbemmcmd command out put asked by Marianne, provide below outputs also

bpimmedia -mediaid <same media iD used in nbemmcmd command>  -L

bpimagelist -backupid <backup id from bpimmedia output> -L

snawaz3's picture

Attached are the outputs. I did not get any output when I ran the bpimagelist cmd.

nbemmcmd.txt 2.42 KB
bpimmedia.txt 2.66 KB
bpimagelist.txt 2.92 KB
RamNagalla's picture

even the media is showing retenction level as 5 (currentlyinfinity), its showing expire date as 02/15/2013 23:36.

i understand that the retenction level 5 is customized, before customization does it used, and if yes, what was the retenction level set to that?

its not showing any entry, did you open your command promt as Administrator( right click ---> RUn as administrator)?

C:\Users\s-shahid.nawaz.ctr>bpimagelist -backupid nduapp26_1358750209 -L

no entity was found
snawaz3's picture

I get the same result 'no entity found". The retention levels were all mixed for different policies. I am trying to make it consistent. Thanks

Marianne's picture

What we see in nbemmcmd output is not making sense.

Time Assigned:                  01/20/2013 12:33
Last Mount:                     01/20/2013 12:35
Data Expiration:                02/15/2013 23:36
Last Written:                   01/20/2013 16:25
Date Vaulted:                   01/21/2013 00:36
This seems to be the 'copy 2' tape (according to bpimmedia).
Tape shows Ret level 5 instead of level 2. I have no explanation for this.
But the expiration date is more or less 4 weeks since backup image timestamps (the ones that we can make out in bpimmedia output - 1358570209 is 01/19/2013 4:36am GMT.)
Any possibility that retention levels were changed more than once?
Time Assigned is perfectly fine - this is the time that tape was selected for duplication - 2 seconds before tape mount.

Supporting Storage Foundation and VCS on Unix and Windows as well as NetBackup on Unix and Windows
Handy NBU Links

snawaz3's picture

It is quite possible that the retention levels could have been changed since I was trying to make it consistent. What I am trying to do is to calculate the expiration date for my tapes so that I can reuse them for my backups. For example. My daily backup tape for Monday. I load the tapes on Monday morning. The backups are scheduled to start at 8.00 PM on Monday. I have had the problem when the vault was set to start at 5.00 AM on Tuesday that the backups would not finish and the vault would start. I was worried that the vault would not be complete if it is writing at the same time that the backup is running. I moved the time of the vault to start at 10.00 AM.

I am having an issue with understanding the expiration time. I had assumed the since they backup started at 8.00 PM and the expiration was set for 7 days they would expire at 8.00 PM the next Monday. That way if I used the same tapes next Monday they would be good. But I discoverd the the expiration date is calculated from the last write time. For exanple. The backup started at 8.00 PM on Monday and continued till 5.00 AM on Tuesday, then the expiry date for that tape would be next Tuesday at 5.00 AM. That way the tape would not be available for writing  at 8.00 Monday. Does this make sense or am I complicating things. Any clarification would be appreciated. Thanks

mph999's picture

The expiration time is calculated from when the backup starts.

Here is a backup from my system

IMAGE nbmaster00 8 nbmaster00_1360882574 tape 0 Full 0 12 531 1360893374 0 0
FRAG 1 1 100096 0 2 6 1 E01012 nbmaster00 262144 2 1360882574 0 0 *NULL* 1360893374 0 12 1 *NULL*
The retention is 3 hrs
the backup time is 
root@nbmaster00 openv $ bpdbm -ctime 1360882574
1360882574 = Thu Feb 14 14:56:14 2013
The backup had to have finished after this time (1360882574)
The expire time is seen on the IMAGE line and converts to ...
root@nbmaster00 openv $ bpdbm -ctime 1360893374
1360893374 = Thu Feb 14 17:56:14 2013
which is exactly, 3 hrs to the second, after the backup started.
Regards,  Martin
Setting Logs in NetBackup:
Marianne's picture

I agree with Martin - expiration date is calculate from backup start date.

Please bear in mind that you have more than one backup image on your tapes. Have another look at nbemmcmd output for KW6554:

Images:                         15

So here the 'Last Written' date will correspond with the start time of last image written to tape.

What I am trying to do is to calculate the expiration date for my tapes... 

Just keep an eye on 'Tape Summary' report.
Run this report on a regular basis with 'Verbose' option selected.


Supporting Storage Foundation and VCS on Unix and Windows as well as NetBackup on Unix and Windows
Handy NBU Links