cancel
Showing results for 
Search instead for 
Did you mean: 

Netbackup backup exclusion

cheech
Level 2

Hi, I have been a frequent reader of these articles in this forum for a while and always found it useful. Now it's my turn to post my own '1st' question here. A  policy backup selection problem, and I wanted to know how to make things as effcient as I possbile can.

I have a request to backup a specific set of file selections on a linux client along the lines of the following:-

/Top_lvl/2nd_lvl/Variable-pxx/LOTS-of-Options/SameOption/*     

But the sub folder 'pxx' currently ranges from p0 to p31 different sub folders and the 'LOTS-of-Options' folder has 5-6 folders chioces, of which I only actually want to pick 1 specific folder to capture the 'SameOption' which all the other 'Variable-pxx' also share (so don't worry about that part) basically that would be a constant and exact folder name at the end.

In reality it is like this:    /naab1/parts/p{0-31}/mfs_16way_000/migration   (I know Linux doesn't acept the brackets but it would have been nice)

I have tried lots of variations of this eg

/Top_lvl/2nd_lvl/*/LOTS-of-Options/SameOption/*     /Top_lvl/2nd_lvl/p*/LOTS-of-Options/SameOption/*

/Top_lvl/2nd_lvl/p%%/LOTS-of-Options/SameOption/*  

I EVEN tried adding in the FULL Range of 32 selections to the policy and it still only did the 1st p0 folder

/Top_lvl/2nd_lvl/p0/LOTS-of-Options/SameOption/* through to  /Top_lvl/2nd_lvl/p31/LOTS-of-Options/SameOption/* 

When I checked in the BAR GUI only p0 was ever backed up. Does anyone know how a 1 line backup selection like the one 1 have in reality would work?

if ONLY it would accept a p{0-32} Type of logic then the whole thing would work with 1 line.

I hope I haven't confused you all and I would really appreciated some thoughts and ideas as it's bugging the kaka out of me :)

I have considered Excludes files but I thought that surely there is a way to do this on 1 line of text.

PS I'm running NBv 7.1  on linux masters and medias (some media srv are still at v7.0)

1 ACCEPTED SOLUTION

Accepted Solutions

RamNagalla
Moderator
Moderator
Partner    VIP    Certified

yes.. i agree with Chris,

 

when you say

 

"I have tried lots of variations of this eg

/Top_lvl/2nd_lvl/*/LOTS-of-Options/SameOption/"

its suppose to full fill your requirement...but its not doing becuase.. there is some issue... that is the reason you are not able to backup even you provided all 32 paths.

once you fix that issue.. your above entry will work for you..

 

make sure the rest of paths are not Link files.

make sure they are correct in case sensitive.. (unix is case sensitive)

make sure they dont have spaces when they created...( and you are giving with out spaces)

 

and try to backup only /Top_lvl/2nd_lvl/p31/LOTS-of-Options/SameOption/*  and see how it works... 

its like only one backup selection at a time..

 

View solution in original post

8 REPLIES 8

CRZ
Level 6
Employee Accredited Certified

What is up, cheech?

Wildcard use in NetBackup on UNIX/Linux
 http://symantec.com/docs/HOWTO33510

I want to say something clever like /Top_lvl/2nd_lvl/Variable-{p[0-9],p[0-9][0-9]}/LOTS-of-Options/SameOption/* but this bit troubles me:

I EVEN tried adding in the FULL Range of 32 selections to the policy and it still only did the 1st p0 folder

/Top_lvl/2nd_lvl/p0/LOTS-of-Options/SameOption/* through to  /Top_lvl/2nd_lvl/p31/LOTS-of-Options/SameOption/*

When I checked in the BAR GUI only p0 was ever backed up.

I think we need to figure out why this would be happening before we figure out your wildcards, because if I understand your description, there's no reason why only p0 would be getting backed up when you're explicitly listing all 32 possible paths unless the other 31 don't exist.

Yasuhisa_Ishika
Level 6
Partner Accredited Certified

I agree with Chris, you need to figure out why only p0 was taken.
I think it is not possible to write your selections one line, but above 3 lines will work.

/Top_lvl/2nd_lvl/p[0-9]/LOTS-of-Options/SameOption/*
/Top_lvl/2nd_lvl/p[1-2][0-9]/LOTS-of-Options/SameOption/*
/Top_lvl/2nd_lvl/p3[0-1]/LOTS-of-Options/SameOption/*

BTW, why you added '*' at the end of each line? For multistreaming?
If so, backup go into multiple jobs. You need to check each backup images.

RamNagalla
Moderator
Moderator
Partner    VIP    Certified

yes.. i agree with Chris,

 

when you say

 

"I have tried lots of variations of this eg

/Top_lvl/2nd_lvl/*/LOTS-of-Options/SameOption/"

its suppose to full fill your requirement...but its not doing becuase.. there is some issue... that is the reason you are not able to backup even you provided all 32 paths.

once you fix that issue.. your above entry will work for you..

 

make sure the rest of paths are not Link files.

make sure they are correct in case sensitive.. (unix is case sensitive)

make sure they dont have spaces when they created...( and you are giving with out spaces)

 

and try to backup only /Top_lvl/2nd_lvl/p31/LOTS-of-Options/SameOption/*  and see how it works... 

its like only one backup selection at a time..

 

cheech
Level 2

Hi there,

Great option to try. When you suggest using the 2 types of brackets are they compatible with use on a linux client? I thought that was a windows client backup only thing?

I take it {p[0-9],p[0-9][0-9]}  should cover anything within p0 thru to p99, and so accomodates fluctuations.. I shall give it a go.

@Chris yes it was a bit odd that the explcits whne checked in BAR on covered p0. I wasn't expecting that

@Yasuhisa not sure if it was needed but I added '*' there at the end to do subsequent folder tree down. I take it that's not necessary then is it?

When I get a chance today I'll experiment with the brackets and let you know how it goes... 

Will_Restore
Level 6

I don't think the curly braces will work

cheech
Level 2

Hi All,

In the end Chris nodding to the correct problem there WAS something wrong with the initally give dir address structure. As not JUST the variables I thought changed. there were more... So I went for this to accommodate them and it worked a treat! 

/naab1/parts/p*/mfs_*way_*/migration/

It seems the mfs* subfolder wasn't as "constant" as I was lead to believe.. Ah Users, were whould we be without them  (Jobless perhaps)  :)

Thanks guys, really good effort and response. I'm very pleased! At the very least I learnt new values I Can use in my file selections with the use of brackets and comma separators! 

Much appreciated

 

 

 

CRZ
Level 6
Employee Accredited Certified

Glad it worked out.  (obligatory begging for marked solution or at least up thumb on my first reply here)

To answer your earlier question, if you check the documentation I linked, you'll see that curly braces AND square brackets can be used all over UNIX (which includes Linux) - limitations only come into play on Windows.

That said, I've never really tried to combine them in that way before and can't guarantee it'll work 100%, but fortunately you've already sorted that just with asterisks.yes

cheech
Level 2

Done the thumbs and marked solution thingy.. (Didn't know I was supposed to so thanks again!)

:)