This is an archive version of the document. To get the most up-to-date information, see the current version.

Set-VBRJobSchedule

Short Description

Modifies job schedule.

Applies to

Platform: VMware, Hyper-V

Product Edition: Standard, Enterprise, Enterprise Plus

Syntax

Set-VBRJobSchedule -Job <CBackupJob> [-Daily] [-At <datetime>] [-DailyKind <DailyKinds> {Everyday | WeekDays | SelectedDays}] [-Days <DayOfWeek[]> {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] [<CommonParameters>]

-OR-

Set-VBRJobSchedule -Job <CBackupJob> [-At <datetime>] [-Days <DayOfWeek[]> {Sunday | Monday | Tuesday | Wednesday | Thursday | Friday | Saturday}] [-Monthly] [-NumberInMonth <EDayNumberInMonth> {First | Second | Third | Fourth | Last | OnDay}] [-Months <EMonth[]> {January | February | March | April | May | June | July | August | September | October | November | December}] [-DayOfMonth <string>]  [<CommonParameters>]

-OR-

Set-VBRJobSchedule -Job <CBackupJob> [-Periodicaly] [-FullPeriod <int>] [-PeriodicallyKind <VBRPeriodicallyKinds> {Hours | Minutes | Continuously}] [-PeriodicallySchedule <VBRBackupWindowOptions>] [-PeriodicallyOffset <int>] [<CommonParameters>]

-OR-

Set-VBRJobSchedule -Job <CBackupJob> [-After] [-AfterJob <CBackupJob>]  [<CommonParameters>]

Detailed Description

This cmdlet modifies schedule settings of a selected job.

You can schedule the job to run:

  • Daily on specific time, on specific days of week.
  • Monthly on specific time, on specific days of month, on specific months.
  • Periodically within specified period of time or continuously.
  • After a certain job you specify.

Parameters

Parameter

Description

Required

Position

Accept
Pipeline
Input

Accept
Wildcard
Characters

Job

Specifies the job you want to edit.

True

Named

True (ByValue,
ByProperty
Name)

False

Daily

For daily schedule.

Indicates that the job runs daily.

False

Named

False

False

At

For daily schedule.

Specifies the job start time.

Default: 10:00.

False

Named

False

False

DailyKind

For daily schedule.

Specifies the days to run the job:

  • Everyday: the job will run everyday.
  • Weekdays: the job will run Monday through Friday.
  • SelectedDays: the job will run on specific days (for example, Saturdays). Use the Days parameter to set the days.

False

Named

False

False

Days

For daily schedule.

Specifies the days of week when the job will run.

False

Named

False

False

Monthly

For monthly schedule.

Indicates that the job runs once a month.

False

Named

False

False

At

For monthly schedule.

Specifies the job start time.

Default: 10:00.

False

Named

False

False

Number
InMonth

For monthly schedule.

Specifies the number of day in month (for example, Saturday):

  • First: the job will run on the first (Saturday) of selected months.
  • Second: the job will run on the second (Saturday) of selected months.
  • Third: the job will run on the third (Saturday) of selected months.
  • Forth: the job will run on the forth (Saturday) of selected months.
  • Last: the job will run on the last (Saturday) of selected months.

False

Named

False

False

Days

For monthly schedule.

Specifies the day of week for the NumberInMonth parameter.

False

Named

False

False

Months

For monthly schedule.

Specifies the months when the job will run: January, February, March, April, May, June, July, August, September, October, November, December.

False

Named

False

False

Periodicaly

For periodical run.

Indicates that the job runs periodically (for example, every 6 hours).

Use FullPeriod and PeriodicallyKind parameters to set the periodical schedule.

Use PeriodicallySchedule parameter to set backup window.

False

Named

False

False

FullPeriod

For periodical run.

Specifies the number of hours or minutes for the PeriodicallyKind parameter.

False

Named

False

False

Periodically
Kind

For periodical run.

Specifies the periodically schedule type:

  • Hours: the job will run periodically in specifies number of hours (for example, every 6 hours).
  • Minutes: the job will run periodically in specified number of minutes (for example, every 30 minutes.
  • Continuously: the job will start right after it finished.

False

Named

False

False

Periodically
Schedule

For periodical run.

Specifies the backup window.

Accepts VBRBackupWindowOptions type.

False

Named

False

False

Periodically
Offset

For periodical run.

Used to set the exact time when the backup window starts.

Specifies the number of minutes (1-59). The job will start at the hour set in the backup window plus the indicated period (for example, at 8:30).

False

Named

False

False

After

For running after a job.

Indicates that the job will start after another job.

Use AfterJob parameter to set the primary job.

False

Named

False

False

AfterJob

For running after a job.

Specifies the job after which you want to run this job.

False

Named

False

False

<CommonParameters>

This cmdlet supports Microsoft PowerShell common parameters. For more information on common parameters, see the About CommonParameters section of Microsoft Docs.

Example 1

This command sets a new schedule to jobs named "Backup Job 01" and "Backup Job 05". The jobs are obtained with Get-VBRJob and piped down. The jobs are scheduled to run daily at 23:00 on weekdays.

Get-VBRJob -Name "Backup Job 01", "Backup Job 05" | Set-VBRJobSchedule -Daily -At "23:00" -DailyKind Weekdays

Example 2

This command schedules all replication jobs to monthly run. The replication jobs are obtained with Get-VBRJob and piped down. The jobs are scheduled to run every last Saturday at 12:00 in February, May, August and December.

Get-VBRJob -Name Replica* | Set-VBRJobSchedule -Monthly -At "12:00" -NumberInMonth Last -Days Saturday  -Months February, May, August, December

Example 3

This command schedules the job represented by the $job variable to run every 12 hours. The job is obtained with Get-VBRJob and assigned to the variable beforehand.

Set-VBRJobSchedule -Job $job -Periodicaly -FullPeriod 12 -PeriodicallyKind Hours

Example 4

This command schedules the job represented by the $job variable to run after the SureBackup job named SureBackup Job 01. The SureBackup Job 01 is obtained with Get-VSBJob and piped down. The backup job is obtained with Get-VBRJob and assigned to $job variable beforehand.

Get-VSBJob -Name "SureBackup Job 01" | Set-VBRJobSchedule -After -AfterJob $job

Related Commands

Get-VBRJob

New-VBRBackupWindowOptions

I want to report a typo

There is a misspelling right here:

 

I want to let the Veeam Documentation Team know about that.