cancel
Showing results for 
Search instead for 
Did you mean: 

Scheduler for NBU Disk Stagging

Shlomo_Nisgav
Level 2
Partner Accredited
To get disk backup/restore benefits and save library slots, disk schedule must be planned. But the existing disk staging NBU 5.1 can not be scheduled and even the watermark in Ver 6 would not satisfied customers request.
Q1 - Do you know of tested script that will handle image transport from disk to tape?
Q2 - Do you know if Veritas will add this flexibility feature in next versions.
Clarification: Requirement - To keep 5 images, 2 on disk and 3 on tapes. Before starting backup, move older image from disk to tape, free disk space.
Why: Because most of the time users ask for last week recovery
1 REPLY 1

Yasuhisa_Ishika
Level 6
Partner Accredited Certified
I think this requirement can be met with bpduplicate and bpexpdate.
sample scripts below are not tested well. Just sample.

1. Run backup with disk storage unit(not stageing unit).


2. Duplicate image to another disk storage unit.


#! /bin/sh

# TARGET: specify policy:schedule:client:range(hours)
TARGET="pol1:sched1:client1:24 pol2:sched2:client2:24"

STU_DISK1="DISK1"
STU_DISK2="DISK2"
STU_TAPES="TAPE1,TAPE2,TAPE3"

for i in ${TARGET}; do
policy=`echo $i | cut -d: -f1`
sched=`echo $i | cut -d: -f2`
client=`echo $i | cut -d: -f3`
range=`echo $i | cut -d: -f4`

# duplicate to 2nd disk storage unit
/usr/openv/netbackup/bin/admincmd/bpduplicate -dstunit ${STU_DISK2} -policy ${policy} -sl ${sched} -client ${client} -hoursago ${range}
done


3 Duplicate image to tapes.


#! /bin/sh

# TARGET: specify policy:schedule:client:range(hours)
TARGET="pol1:sched1:client1:24 pol2:sched2:client2:24"

STU_DISK1="DISK1"
STU_DISK2="DISK2"
STU_TAPES="TAPE1,TAPE2,TAPE3"

for i in ${TARGET}; do
policy=`echo $i | cut -d: -f1`
sched=`echo $i | cut -d: -f2`
client=`echo $i | cut -d: -f3`
range=`echo $i | cut -d: -f4`

# duplicate to tapes
/usr/openv/netbackup/bin/admincmd/bpduplicate -dstunit ${STU_TAPES} -policy ${policy} -sl ${sched} -client ${client} -hoursago ${range}
done


4. Before next backup, expire images on disk storage units with bpexpdate.

#! /bin/sh

# TARGET: specify policy:schedule:client:range(hours)
TARGET="pol1:sched1:client1:24 pol2:sched2:client2:24"

STU_DISK1="DISK1"
STU_DISK2="DISK2"
STU_TAPES="TAPE1,TAPE2,TAPE3"

for i in ${TARGET}; do
policy=`echo $i | cut -d: -f1`
sched=`echo $i | cut -d: -f2`
client=`echo $i | cut -d: -f3`
range=`echo $i | cut -d: -f4`

# expire images on disk(copy number are 1 and 2, maybe)
backupids=`/usr/openv/netbackup/bin/admincmd/bpimagelist ${STU_TAPES} -policy ${policy} -sl ${sched} -client ${client} -hoursago ${range} | cut -f6 -d" "`

for j in ${backupids}; do
/usr/openv/netbackup/bin/admincmd/bpexpdate -backupid $j -copy 1 -force -d 0
/usr/openv/netbackup/bin/admincmd/bpexpdate -backupid $j -copy 2 -force -d 0
done
done