Modifying a schedule for an existing job in Backup Exec 2012 with PowerShell

With PowerShell for Backup Exec, you can get a list of jobs from Backup Exec 2012 by typing Get-BEJob, which will give you a list of all the jobs in Backup Exec as in the below example. (This might also be a good time to make sure that all your backup jobs are descriptive enough as to identify individual ones)

image

The name of the job is listed under Name, the –Full appended to the end is automatically added by Backup Exec 2012 to indicate the backup task.

As you can see, the backup job for Test 2 only runs once a week, on a Friday at 11pm, this really doesn’t suit my needs for a production server, so I want to change it to match the same schedule as Test. To do this I need to type in the following command.

Get-BEBackupDefinition -Name “Test 2” | Set-BEFullBackupTask -Name Full -Schedule (New-BESchedule -Weekdays -StartingAt “10:00PM 19/3/12”) | Save-BEBackupDefinition

image

Get-BEBackupDefinition – Name is looking for the name of the backup job, while Set-BEFullBackupTask – Name is looking for the TaskName, both of which you get from the Get-BEJob command.

You can also use 24 hour time and date formats such as dd/mm/yyyy (or mm/dd/yyyy) depending on your locale

Once you have modified your schedule you can get it by running Get-BEJob again and seeing the schedule.

image

Advertisements

About Phill McSherry
Phill McSherry has been working in the Australian IT industry for over 20 years and is the technical manager and solutions architect for managed services provider Titan Solutions - www.titansolutions.com.au

One Response to Modifying a schedule for an existing job in Backup Exec 2012 with PowerShell

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: