Video Screencast Help

NetBackup VOLUME retention level change

Created: 26 Oct 2010 | 11 comments

Hi all:

I reset the retention for an image using bpexpdate - no problem.  bpmediaelist still shows the old retention level for the media, however.  It shows the proper expiration date (to match the new retention I set), but I have a bunch of scripts that key off of the retention level.  Is there a way to change this entry?  Everything I find points be towards bpexpdate to change image retentions, but this is not my issue.

 id     rl  images   allocated        last updated      density  kbytes restores
           vimages   expiration       last read         <------- STATUS ------->
--------------------------------------------------------------------------------
LT0072   1      1   10/25/2010 09:44  10/25/2010 09:44   hcart   848635648     0
                1   10/24/2012 09:44        N/A         FULL
 

Comments 11 CommentsJump to latest comment

Nicolai's picture

Done that long time ago - as far as I can recall you need to do a

bpexpdat -recalculate -backupid {backup_id} -ret retention_level

This will set set the expiration of the backup as it was newly made with life time of the defined retension level.

Assumption is the mother of all mess ups.

If this post answered your'e qustion -  Please mark as a soloution.

Zahid.Haseeb's picture

Dear friend first you should had written what version of Netbackup Server you are running

Any how try this. It may help you

Before doing reset the retention level of backup images must make a duplicate copy for securing your backup image from any sort of  corruption/expiration.

 

Before taking the backup

you can set the retention in policy -- schedules --retention ---...After that you can fire the backup .

After taking the backup

take the help of bpexpdate command for exact syntax:- OR it might be

bpexpdate -recalculate -backupid -ret  retention

 

Any comment will be appreciated. Mark as Solution if your query is resolved
__________________
Thanks in Advance
Zahid Haseeb

zahidhaseeb.wordpress.com

Zahid.Haseeb's picture

This might help you too

http://alcor.concordia.ca/manpages/loc1/bpexpdate.1.html

Any comment will be appreciated. Mark as Solution if your query is resolved
__________________
Thanks in Advance
Zahid Haseeb

zahidhaseeb.wordpress.com

J.H Is gone's picture

If you look at the retention levels on the master properties...

you see that each level has a length of time to it.

Well when you make a backup, the policy/schedule says what retention level to assign to the images.

Now that retention level stays logged to that image, even if you change your expiration date.

Say you started out with a retention level of 1 (2 weeks)  then you change the expiration date to be a total of 16 days from creation - there is no retention level that matches that 16 days from creation.....

So you can change the expiration date of the image ( and it not be equal to any retention level) or you as Nicolai suggested and set the image to a new retention level with recalculation from the original creation date equal to the new retention level.

I don't have to know how to spell....I work on Unix.
NetBackup 7.0.1 - AIX & Windows

bills's picture

Zahid - Thanks for reminding me to post the version - 6.5.5.

Thanks to all who responded.  I had hoped that my original post had been clear enough, but apparently not.  I am not looking to change the expiration date for an image.  I have already done that successfully.  I am trying to change the retention level associated with the volume in the media database.

The problem I have is that, when the image was created with retention level 1, it got put onto a new tape which then adopted the same retention level (as seen with bpmedialist).  I changed the retention of the image to 12.  bpimagelist shows the proper expiration.  bpmedialist, however, still shows the volumes with retention level 1 - even though the expiration is listed correctly.  I have many scripts that key off of the volume retention level, assuming that the retention levels of images contained on that volume will match.

Is there a way to rewrite the retention level field read by bpmedialist?

Zahid.Haseeb's picture

As J.Hinchcliffe says

 

""""""Say you started out with a retention level of 1 (2 weeks)  then you change the expiration date to be a total of 16 days from creation - there is no retention level that matches that 16 days from creation.....

So you can change the expiration date of the image ( and it not be equal to any retention level)""""""

 

If you are still confused do one thing. Make a backup and recalculate it but picked any retention level (see the picture for a reference) from the below picture...After my suggestion see that your exact retention level is showing ? if yes thn as J.Hinchcliffe said( there is no retention level that matches that 16 days from creation) its true

 

Any comment will be appreciated. Mark as Solution if your query is resolved
__________________
Thanks in Advance
Zahid Haseeb

zahidhaseeb.wordpress.com

Andy Welburn's picture

I understand what you are saying but it's not (or at least does not appear) possible with bpexpdate (& certainly not with bpmedialist).

Just proved or confirmed same here with a little test:

* backed up one image to tape with monthly retention (only image on tape)
* recalculated retention of that image (cannot set r/l by media unfortunately) to infinity
* checked that image has new r/l but media still has original r/l (altho' expiry date does change)

At this moment all I can think to resolve this for you would be to duplicate those images & set the duplicates to the correct r/l, then expire the original media/images.
 

Zahid.Haseeb's picture

To read and understand more about Retention see page # 144 RETENTION under "Netbackup Administration Guide Vol-1 (for wndows)"

Guide link below:-

http://www.symantec.com/business/support/index?page=content&id=TECH52803

Any comment will be appreciated. Mark as Solution if your query is resolved
__________________
Thanks in Advance
Zahid Haseeb

zahidhaseeb.wordpress.com

bills's picture

Andy:

Nothing really has changed on my end.  All the responses to this post deal with image retention levels and changing these via bpexpdate.  Nothing here has addressed my question:

can I change the retention level listed for a volume by bpmedialist?

You at least seem to understand what I was asking, and recommended duplication.  I was hoping for a better solution, that's all.

 

Thanks for the help

Bill

Andy Welburn's picture

Can't think of one, sorry! bpmedialist will do just that - list media info. I did think I'd found you another resolution yesterday using vmchange but unfortunately I was getting my retentions & expiries mixed up!

All I can think of is that the r/l gets set for the media when the first image is written to it or when it's first assigned from scratch for a backup - in which case that could be very confusing if you allowed mixed retentions on media - & then cannot be changed or will not change until it's next assigned after all the images have expired. Just guessing here so could well be totally wrong!