I'm figuring an issue with an post-job PS-script of a Reverse-Incremental Backup-Job of a VMware-Host.
This post-job script is been started by a link-batch in the backup-job and looks as follows:
Code: Select all
Start-Sleep -S 60
Add-PSSnapin VeeamPSSnapin
if (get-command | Where-Object {$_.Name -eq "Connect-VBRServer"}) {Connect-VBRServer -Server $env:VEEAMSERVER}
$VBRBackupJobName = "BackupJob"
$VBRLastBackupSuccess = (Get-VBRJob | where {$_.Name -eq $VBRBackupJobName}).GetLastResult() -eq "Success" -OR (Get-VBRJob | where {$_.Name -eq $VBRBackupJobName}).GetLastResult() -eq "Warning"
if(!$VBRLastBackupSuccess){invoke-item "C:\scripts\sync_backup.cmd"}
else{Exit Script}
My idea is now to build some kind of query that checks the merging to be finished bevor going on.
Has anyone faced a similar problem and has an idea how i could build something like that? Or maybe have some advice?
Thanks in advance