This issue has been solved.

Script

Created: 10 Oct 2012 | Updated: 10 Oct 2012
Login to vote
0 0 Votes

Hi Team,

Could you please provide me a script to get quickly the policy name for 'n' numbers of clients.

Thanks,

Gopinath S

Quick Look Solution

You can shorten the awk/sed

You can shorten the awk/sed portion...

 

bpcoverage -c $CLIENT -no_client_query -hardware -no_hw_header -no_cov_header | awk 'NR>6{print $1}'

 

 

 

 

Filed Under

Comments

Ashish-Sharma's picture
Ashish-Sharma
Accredited
10
Oct
2012
Votes
+1

Hi, Check

Thanks In Advance

Ashish Sharma

SEPM Knowledgebase Documents  

 

Andy Welburn's picture
Andy Welburn
Trusted Advisor
10
Oct
2012
Votes
+1

From Ashish's post, *your

From Ashish's post, *your thread* being the operative words!

 

Just put the command in Martins post (solution) within a 'loop'

e.g.

for CLIENT in client1 client2 client3 client4
do
bpcoverage -c $CLIENT  -no_client_query -hardware -no_hw_header -no_cov_header |awk '{print $1}' |sed 's/^CLIENT//g' |sed 's/^://' |sed 's/^Policy//' |sed 's/-//g'
done

 

***EDIT***

@Ashish: You really didn't need to edit your post! I was pointing out the fact (to the OP) that you'd pointed him to *his own* thread & therefore, from my POV, the answer was already available him! I thought your original wording was *very* appropriate!

Nathan Kippen's picture
Nathan Kippen
Certified
10
Oct
2012
Votes
0
SOLUTION

You can shorten the awk/sed

You can shorten the awk/sed portion...

 

bpcoverage -c $CLIENT -no_client_query -hardware -no_hw_header -no_cov_header | awk 'NR>6{print $1}'

 

 

 

 

Symantec Certified Specialist in Symantec NetBackup 7.0
(NBU 7.5.0.4)
Don't forget to vote or mark solution!

10
Oct
2012
Votes
0

Hi Team, Thanks for all your

Hi Team,

Thanks for all your help Mates.

Thanks,

Gopinath S