cancel
Showing results for 
Search instead for 
Did you mean: 

Need opscenter analytics script for FULL backups

noazara
VIP
   VIP   

I need a Netbackup script to check what all active clients do not have full backup from last 1 month.(active clients only --- not for clients which are in the deactivated policy)

I need only client details which are in the Activated policy only.

I have VIP environment.Vmware backups using VIP(Query)

or a SQL query for OPSCENTER Analytics will also help.

I need for both VM in the VMware backup policy and also in the Standard windows backups policy .

 

@ Krutons, if you can help here plz.

1 ACCEPTED SOLUTION

Accepted Solutions

Marianne
Moderator
Moderator
Partner    VIP    Accredited Certified

@noazara 

After all this time, we can safely assume the following:

  1. None of the 'regulars' on this forums have such a script readily available
  2. Hardly any of the backup admins in this forum have specialized scripting skills
  3. Busy backup admins who do have scripting skills simply do not have the time to figure out a complex script for which they do not have any use
  4. Any script that uses Policy config to obtain Client list will NOT work with Intelligent Policies
  5. Skilled scriptwriters expect to be paid for custom scripts.

Maybe it's time to approach your issue differently. 
Start a new post in which you explain your real issue: 


@noazara wrote:


We are facing escalations because of skip of FULL backups from 1000 of VM in the environment.

We have around 20 deactivated policies and 50 activated policy.


Ask fellow backup admins how they go about to avoid skipped VM backups.

In the meantime, work with your VM admins - look at the VMware environment as if this is a brand new backup setup.
Let your VM admins give you an inventory of VMs and list backup needs. 
Look at Intelligent Policy selection criteria to ensure that all expected VMs will be picked up when backup is due, even if they are moved to another ESX host, powered off, etc. 
Confirm selection with 'Test Query'. Review time period in 'Reuse VM selection query results for'. 
As per the manual, this is normally the reason for skipped backups:

Because the automatic selection feature is dynamic, later changes in the environment may affect which virtual machines match the query rules. For example: if virtual machines are added later, the current test results may not be identical to the virtual machines that are selected when the backup runs.

During the period you specify on Reuse VM selection query results for, NetBackup reuses the current list of virtual machines as the backup list. It does not consult the Query Builder or rediscover virtual machines.

The less often your virtual machine environment undergoes changes, the more advantageous it may be to reuse the list of virtual machines for backups. In large environments, discovery of virtual machines takes time and consumes resources on the vCenter server.

Please consider the following method to find skipped VMs: 
When you have the VM inventory, use a simple bpimagelist command to list all clients in VMware policies with successful Full backups for a specified period.
Use 'diff' to compare with your VMware inventory list.

Also best to get rid of deactivated policies. 
If you really need to keep a copy, do a Full Catalog backup with fairly long retention. You can restore individual policies from a Catalog backup. 
Else, move the relevant folders under 'class' directory to a different location and then delete these policies.

 

View solution in original post

10 REPLIES 10

Krutons
Moderator
Moderator
   VIP   

This should probably be under the OpsCenter section.

I'm quite busy with my current workload and I'm not an SQL guru @noazara 
When I have some downtime, I'll try to take a look

noazara
VIP
   VIP   

Thanks Kruton.

 

Did you get the chance to look at it..

Tape_Archived
Moderator
Moderator
   VIP   

Try "Clients Not Backed Up" OpsCenter report and see if that helps you.

Login to OpsCenter => Reports => Report Templates => Client Reports => Clients Not Backed up

Thanks Tape_Archive

That includes clients with the deactivated policy as well.

I need for active policies clients only.

noazara
VIP
   VIP   

Hi Guys,

 

ANy help on this please

Marianne
Moderator
Moderator
Partner    VIP    Accredited Certified

To quote @Mouse  in his reply over here: https://vox.veritas.com/t5/NetBackup/Netbackup-script-to-check-what-all-active-clients-do-not-have/m...

' .... usually if you need a custom scripting job done and have no idea how to do it, you'd hire someone and reasonably expected to pay for it.'

With the level of scripting that you require, maybe time to hire a consultant? 

noazara
VIP
   VIP   

Hi Guys,

 

We are facing escalations because of skip of FULL backups from 1000 of VM in the environment.

 

We have around 20 deactivated policies and 50 activated policy.Thats why i need help in here.

 

I need details for Active clients in the activated policy.

noazara
VIP
   VIP   

Need Help here urgentlly

Marianne
Moderator
Moderator
Partner    VIP    Accredited Certified

@noazara 

After all this time, we can safely assume the following:

  1. None of the 'regulars' on this forums have such a script readily available
  2. Hardly any of the backup admins in this forum have specialized scripting skills
  3. Busy backup admins who do have scripting skills simply do not have the time to figure out a complex script for which they do not have any use
  4. Any script that uses Policy config to obtain Client list will NOT work with Intelligent Policies
  5. Skilled scriptwriters expect to be paid for custom scripts.

Maybe it's time to approach your issue differently. 
Start a new post in which you explain your real issue: 


@noazara wrote:


We are facing escalations because of skip of FULL backups from 1000 of VM in the environment.

We have around 20 deactivated policies and 50 activated policy.


Ask fellow backup admins how they go about to avoid skipped VM backups.

In the meantime, work with your VM admins - look at the VMware environment as if this is a brand new backup setup.
Let your VM admins give you an inventory of VMs and list backup needs. 
Look at Intelligent Policy selection criteria to ensure that all expected VMs will be picked up when backup is due, even if they are moved to another ESX host, powered off, etc. 
Confirm selection with 'Test Query'. Review time period in 'Reuse VM selection query results for'. 
As per the manual, this is normally the reason for skipped backups:

Because the automatic selection feature is dynamic, later changes in the environment may affect which virtual machines match the query rules. For example: if virtual machines are added later, the current test results may not be identical to the virtual machines that are selected when the backup runs.

During the period you specify on Reuse VM selection query results for, NetBackup reuses the current list of virtual machines as the backup list. It does not consult the Query Builder or rediscover virtual machines.

The less often your virtual machine environment undergoes changes, the more advantageous it may be to reuse the list of virtual machines for backups. In large environments, discovery of virtual machines takes time and consumes resources on the vCenter server.

Please consider the following method to find skipped VMs: 
When you have the VM inventory, use a simple bpimagelist command to list all clients in VMware policies with successful Full backups for a specified period.
Use 'diff' to compare with your VMware inventory list.

Also best to get rid of deactivated policies. 
If you really need to keep a copy, do a Full Catalog backup with fairly long retention. You can restore individual policies from a Catalog backup. 
Else, move the relevant folders under 'class' directory to a different location and then delete these policies.

 

Steve262
Level 3

Hi,

 

you could try something like this it might give you what you want - 

 

select distinct clientname from domain_policyclient where clientname not in ( select b.clientname from domain_job b where DATEDIFF(day,UTCBigIntToNomTime(b.startTime), GETDATE()) < 30 and scheduleName in ( 'FULL','Full' ) ) and isvalid = 1 and policyname like '%yourpolicynames%' and clientname like '%yourclientnames%' order by clientname

 

 

Steve