PowerShell script exchange
Post Reply
icoaus
Novice
Posts: 6
Liked: never
Joined: Jul 13, 2010 9:07 am
Full Name: Matt Chan
Contact:

Update repository in Job

Post by icoaus »

Hi All,

I am looking into migrating all my backups to a new larger repository. After checking these forums, the steps are

create repository, copy backups, rescan repository, then
1) update repository in job
2) set job mapping to the correct backup / folder

as we have almost 100 jobs, i am looking at doing 1) and 2) via powershell, however i can't see how to update a repository in an existing job, and have no idea how to set the job mapping.

Can anyone assist with this?

thanks,
Matt
Andreas Neufert
VP, Product Management
Posts: 6747
Liked: 1408 times
Joined: May 04, 2011 8:36 am
Full Name: Andreas Neufert
Location: Germany
Contact:

Re: Update repository in Job

Post by Andreas Neufert »

Hi matt, search for andys scripting corner in the powershell forum. There are a lot of examples that show how todo this. There are also examples which automates the repository selection process ( most free disc space)

CU Andy
icoaus
Novice
Posts: 6
Liked: never
Joined: Jul 13, 2010 9:07 am
Full Name: Matt Chan
Contact:

Re: Update repository in Job

Post by icoaus »

Hi Andy,

thanks for your reply.

I have had a look through and found the script you mentioned - Automatic job creation/filling.

However I am not trying to create a new job at which time it is simple to set the repository, but i am looking to update the repository on an existing job. As far as I can see, none of your scripts do that.

Any suggestions on that task?

cheers,
Matt
Andreas Neufert
VP, Product Management
Posts: 6747
Liked: 1408 times
Joined: May 04, 2011 8:36 am
Full Name: Andreas Neufert
Location: Germany
Contact:

Re: Update repository in Job

Post by Andreas Neufert »

Uh, sorry my fault.
I didn´t know the right command now.
As a workaround till I figured it our, you can read out all job configuration, delete the job and create a new one with same details + new repository.
You can use Map existing Backups if you transfered the filew before you did this.

CU Andy
Sethbartlett
Veteran
Posts: 282
Liked: 26 times
Joined: Nov 10, 2010 6:51 pm
Full Name: Seth Bartlett
Contact:

Re: Update repository in Job

Post by Sethbartlett »

I could probably come up with an unsupported way to do this on a scripted level. Up to you if you'd like :)
Skype: Sethbartlett88 - Make sure to label who you are and why you want to add me ;)
Twitter: @sethbartlett
If my post was helpful, please like it. Sometimes twitter is quicker to hit me up if you need me.
icoaus
Novice
Posts: 6
Liked: never
Joined: Jul 13, 2010 9:07 am
Full Name: Matt Chan
Contact:

Re: Update repository in Job

Post by icoaus »

Hi Guys,

Thanks for your input, but i've worked around the problem for now.

I simply ensured that after copying the backup files that the new repository had the same drive letter / folder name as the original one (fortunately it was on the same host) and so there were no changes to the jobs required. Still interesting that there is no (simple) way to update the repository on a Job. Maybe this is commandlet that needs to be added.

cheers,
Matt
Post Reply

Who is online

Users browsing this forum: No registered users and 14 guests