In our environment we have 2 hyper-v clusters backed up by one VEEAM virual server and sql express database. to add a new VM in a JOB we run the script below, which takes 40-50 minutes to add thru script.
We use to have one 21 Node Cluster backing up with VEEAM, the same script use to add new VMS in a job between 5-10 seconds.
After adding a 3 Node Cluster to be backed up with same VEEAM server and using the same script, it now takes 40-50 minutes per VM to be added in a JOB.
Can you please see what needs to be fixed or are there files that we need to clean up to make this faster.
The Find-VBRHvEntity is heavy query taking some time to process. You'd be better run it outside of a cycle once without any filtering parameters. Assign result to a variable, and filter it out later on, using the corresponding VM names. Thanks.