cancel
Showing results for 
Search instead for 
Did you mean: 

deleting disk images

manatee
Level 6

NBU 7.5.0.5, master server redhat linux 6.x

due to a messy SLP, my PD free space has gone very low. now i created the below script hoping to automate and make it fast to delete disk images that already have tape dedups. individually, the commands work but i just want some input from different perspectives as i could have overlooked something.

 

#!/bin/sh

/usr/openv/netbackup/bin/admincmd/nbstlutil list -backupid $1 -U | grep "Copy State"|awk '{ if ($5 == "\(COMPLETE\)") /usr/openv/netbackup/bin/admincmd/bpexpdate -backupid $1 -copy 1 -d 0 ) }'

 

 

the awk statement is looking for the "Copy State" that says "COMPLETE". when found, it'll delete the disk image. i would still have to press "y" for the delete to continue.

appreciate any feedback.

1 ACCEPTED SOLUTION

Accepted Solutions

AZ_Dave
Level 3

Hi Rino19ny

 

From the command guide:

-force
Before you run the specified operation, bpexpdate queries before it starts the
operation. This option forces the bpexpdate command to carry out the operation
without querying the user.

--AZ Dave

View solution in original post

2 REPLIES 2

AZ_Dave
Level 3

Hi Rino19ny

 

From the command guide:

-force
Before you run the specified operation, bpexpdate queries before it starts the
operation. This option forces the bpexpdate command to carry out the operation
without querying the user.

--AZ Dave

manatee
Level 6

hi, yes i soon found out about this after posting :)

thanks.