06-27-2012 10:40 AM
We are looking to use the BPEXPDATE comment to change the retention period for multiple Backup IDs simultaneously. Does anyone know if there's a way to do this?
I am aware that this can be done on an individual basis, but we'd like to do this for many Backup IDs all at once.
Thanks,
Sven
Solved! Go to Solution.
06-27-2012 11:31 AM
Run it in a script - presumeing here they ill all have the same date
Put backupids in file1
cat file1 |while read LINE
do
bpexpdate -d <date > -backupid $LIINE -force
done
This is unix/ linux - not sure how to do it on windows, but someone should be able to help, or just google it ...
Martin
06-27-2012 11:21 AM
-backupid
Changes the expiration of a single backup
per the Command Reference manual
06-27-2012 11:31 AM
Run it in a script - presumeing here they ill all have the same date
Put backupids in file1
cat file1 |while read LINE
do
bpexpdate -d <date > -backupid $LIINE -force
done
This is unix/ linux - not sure how to do it on windows, but someone should be able to help, or just google it ...
Martin
06-27-2012 11:51 AM
.... can be used for Windows.
Thanks,
Sven
06-27-2012 12:36 PM
One way ...
http://www.unix.com/shell-programming-scripting/94219-while-read-line-do-windows.html
Then use the unix version ...
06-27-2012 01:06 PM
Be aware, that if you extend the retention of ONE backup image on a tape, you extend THE WHOLE tape.
Plan carefully, measure twice and cut once!
There are options to search for images by client or policy or retention - as long as you can group by these it is pretty simple.
Just checking the bpexpdate man page, if you can generate a list of media a simple for/next loop will do the trick...
NAME
bpexpdate - change expiration date of backups in image catalog and media in media catalog
SYNOPSIS
<admin_dir_path>bpexpdate -m media_id -d date | 0 | infinity [-host name] [-force] [-nodelete] [-notimmediate] [-M master_server,...]
<admin_dir_path>bpexpdate -deassignempty [-m media_id] [-force] [-M master_server,...]
<admin_dir_path>bpexpdate -backupid backup_id -d date | 0 | infinity [-client name] [-copy number] [-force] [-nodelete] [-notimmediate] [-M master_server,...]
<admin_dir_path>bpexpdate -recalculate [-backupid backup_id] [-copy number] [-d date | 0 | infinity] [-client name] [-policy name] [-ret retention_level] [-sched type] [-M master_server,...]
<admin_dir_path>bpexpdate -stype server_type [-dp disk_pool_name [-dv disk_volume]] [-nodelete]
[-notimmediate] [-M master_server,...]
11-14-2018 08:31 PM - edited 11-14-2018 08:32 PM
There is correction in command bpexpdate -d <date > -backupid $LINE -force instead of LIINE