cancel
Showing results for 
Search instead for 
Did you mean: 

Restore information

maddynick4u
Level 4
 Hi There

My enviorment is 6.0 running on linux and we have some restores in the past and now my concern is how can i know the what are the restore jobs , I have all the backup id's avaialable but how can I get all the information . like policy name , backup id's schedule type ,client name retention level 

What I did was I have copied all the backup id's copied to one file example A and now i have another file B in that we have all the information like client name backup id , schedule type schedule name policy type and other stuff the list goes on , 

I want to compare the records of A and Records of B (based on backup ID) I.e Comapring the backup id's from A and looking for the records in B (file) with same backup id records  I have some thousands of backup id's in file A and 3 times the record of A in file B ,I need some one's help desperately .

Can any one know how to do this ,

Is there any command or any script available to resolve this , All the inputs are appreciated ,According to my knowledege script is perfect 
7 REPLIES 7

Yasuhisa_Ishika
Level 6
Partner Accredited Certified

Have you already tried [NetBackup Management]-[Reports]-[Images on Media] on GUI? You also export this report into text file, from [File]-[Export] menu.

In addition, bpimagelist command shows all the information for each backup images. "bpimagelist -l" is useful for scripting.
support.veritas.com/docs/290234

maddynick4u
Level 4
 Hi Yasuhisa

My question here is I have copied all the images(10000)  from catalog to a text file and after that using command line interface I got some output which shows Backup id's .


In File B
then again through another command  bpimmedia/bpimage -d dd/mm/yy  HH:MM:SS -e mm/dd/yyyy HH:mm:SS, I got Clientname,scheduletype,policy,policytype,Schedlabel ,retention level,backuptime,expiration time,compressed,primary copy...........

Now using the first file backup id's I want to extract all the information like Clinetname, backupid, policy,policyname,schedule type  which are present in second file 

I am comparing the backup Id's of both the file and if the backup ids matches then print the following information from file 2

Clientname ,policy,policytype,sched type,backup id




maddynick4u
Level 4
Can any one please solve my query , please

 

Yasuhisa_Ishika
Level 6
Partner Accredited Certified
bpimagelist command shows all the information for each backup images, including backup id, policy name, schedule label, client, backuptime and etc.

# bpimmedia -l -d 01/01/1970 | grep "^IMAGE" | while read head client i j k backupid policy policytype proxy creator schedule scheduletype retentionlevel backuptime elapsedtime expirationtime compress encrypt kbytes files ncopies nfragments dbcompress ffname and_so_on;do
        echo "${backupid} ${policy} ${schedule} ${client} ${retentionlevel}"
done

It seems this is enoungh to your needs.
Do you have to get info from file A and file B anyway? If so just run grep for each backup id.

# while read id; do grep id B;done < A

maddynick4u
Level 4
I can't really grep for 2700 id's

when you run this command
bpimagelist -A -d 01/01/2007 00:00:00 -e 10/17/2008 23:59:59 
you will get a huge output which shows all the information about your images once you get this information into one file then in another file B I have some backup id's which have been restored now my concern is how can I extract the information using the below command for only those backup id's which were restored
bpimagelist -A -d 01/01/2009 00:00:00 -e 07/17/2009 23:59:59

Yasuhisa_Ishika
Level 6
Partner Accredited Certified
Have you ever tried below? With this commandline, you don't have to run grep 2700times. This runs grep to file B for each line in file A. >Do you have to get info from file A and file B anyway? If so just run grep for each backup id. ># while read id; do grep id B;done < A

Yasuhisa_Ishika
Level 6
Partner Accredited Certified
# while read id; do grep ${id} B; done < A