BE 2012 - Run Job At Certain Hourly Intervals Between Certain Hours Of The Day.
Scenario:
I want to run my SQL log backup or increment backup job on the hour every x hour between 9 a.m. and 5 p.m. during the week-days.
Solution:
BE 2010 or earlier
With BE 2010 or earlier versions of BE, this can be done with a combination of the restart interval and time window of the job property. You set your job to start at 9 a.m. for each week-day. The time window for the job would be 8 hours and the restart interval would be x hour. This will cause the job to start every x hour on the hour from 9 a.m. to 5 p.m.
BE 2012
BE 2012 does not have restart interval. To achieve the above scenario, you would use a combination of hourly recurrance and BEMCLI cmdlets.
1) Set up your SQL log backup or incremental backup job.
These jobs must be setup as part of a scheduled backup and the full backup must be done at least once.
The properties of these jobs must specify the hourly recurrance. For example,
The above screenshot shows 2 hours, but you can change it to the interval that is required, like x hour.
If nothing else is done, then the above incremental backup job will run every x hour throughout the day everyday. This is not what is needed.
2) Use BEMCLI to stop and resume the job
To restrict the SQL log backup or incremental job to run during the hours desired, you got to use the Windows Scheduler to schedule the BEMCLI cmdlets
Get-BEJob "incr-2" | Suspend-BEJob
and
Get-BEJob "incr-2" | Resume-BEJob
Comments 2 Comments • Jump to latest comment
This is very beautifull but Be2012 shouldn't loose settings.
I've putted this in the idea area to be putted again in the be2012
https://www-secure.symantec.com/connect/ideas/weekdays-month-be-2012#comment-7377341
Would you like to reply?
Login or Register to post your comment.