PowerShell script exchange
Post Reply
Jamesdld23
Enthusiast
Posts: 25
Liked: 6 times
Joined: Aug 19, 2016 12:59 pm
Full Name: James Dumont
Contact:

Launch Backup Copy Job exclusively through PowerShell

Post by Jamesdld23 »

Hello,

I am currently launching a Backup Copy Job (BCJ) through a script that is launched after the execution of a Backup Job.
I use the the command "Sync-VBRBackupCopyJob -Job $Job" to do that.

My problem is that the job can also be ran automatically when the BCJ's copy interval is reached, it would have been perfect for me if the Sync-VBRBackupCopyJob command could perform a reset the time beginning of the copy interval.

To give more context, I need to use a script because of the following reason :

My BCJ's target repository is a StorSimple applicance, when all data is received I launch a job that exteranizes the data to the cloud (a cloud snapshot)
The BCJ should only be run when no cloud snapshot are running


Thanks for helping
James
Jamesdld23
Enthusiast
Posts: 25
Liked: 6 times
Joined: Aug 19, 2016 12:59 pm
Full Name: James Dumont
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by Jamesdld23 »

Not sure about it but does this command could do the job?
Disable-VBRJobSchedule -Job $job
veremin
Product Manager
Posts: 20415
Liked: 2302 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by veremin »

Hmm, the mentioned cmdlet issues Sync Now command to a backup copy job. In case of copy interval being equal to one or more days this command should start a new cycle on the following day.

Doesn't it happen in your case or you're after something else?

Thanks.
Jamesdld23
Enthusiast
Posts: 25
Liked: 6 times
Joined: Aug 19, 2016 12:59 pm
Full Name: James Dumont
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by Jamesdld23 »

The job is configured to launch a "copy every" 7 days, my script launches it about every 3 days (with the Sync-VBRBackupCopyJob cmdlet) and I observed that it launches itself after 7 days ...
This last automatic launch occur at this date : 06:25 29/11/2016, I will see in 7 days what will happen.
veremin
Product Manager
Posts: 20415
Liked: 2302 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by veremin »

Hmm, looks strange, because in your case interval should get reset every three days and weekly interval (started the next day) should never finish. Thanks.
Jamesdld23
Enthusiast
Posts: 25
Liked: 6 times
Joined: Aug 19, 2016 12:59 pm
Full Name: James Dumont
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by Jamesdld23 »

I think that what did reset the cycle was a reboot of the Veeam Backup & Replication server.
Is it possible?
veremin
Product Manager
Posts: 20415
Liked: 2302 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Launch Backup Copy Job exclusively through PowerShell

Post by veremin »

Nope, unless you've included other commands in your script. Thanks.
Post Reply

Who is online

Users browsing this forum: Bing [Bot], Majestic-12 [Bot] and 6 guests