How to get the repository a bk job uses

PowerShell script exchange

How to get the repository a bk job uses

Veeam Logoby Dario.Palmisano » Tue Feb 17, 2015 2:29 pm

Hello,

I would like to be able to extract, with powershell, the repository a backup job uses, but till now unsuccessfully.

I wonder if is it possible and how?

Thanks and regards

Dario
Dario.Palmisano
Enthusiast
 
Posts: 29
Liked: 2 times
Joined: Mon Nov 11, 2013 7:22 am
Full Name: Dario Palmisano

Re: How to get the repository a bk job uses

Veeam Logoby v.Eremin » Tue Feb 17, 2015 2:33 pm

Hi, Dario,

Try the following example:

Code: Select all
$Job = Get-VBRJob -name "Name of your Backup Job"
Get-VBRBackupRepository | where {$_.id -eq $Job.Info.TargetRepositoryId} | select name


Thanks.
v.Eremin
Veeam Software
 
Posts: 13281
Liked: 970 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin

Re: How to get the repository a bk job uses

Veeam Logoby Dario.Palmisano » Tue Feb 17, 2015 2:40 pm 1 person likes this post

It works great!

Thanks
Dario.Palmisano
Enthusiast
 
Posts: 29
Liked: 2 times
Joined: Mon Nov 11, 2013 7:22 am
Full Name: Dario Palmisano

Re: How to get the repository a bk job uses

Veeam Logoby v.Eremin » Tue Feb 17, 2015 2:43 pm

You're welcome. Should other help be needed, don't hesitate to let us know.
v.Eremin
Veeam Software
 
Posts: 13281
Liked: 970 times
Joined: Fri Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin


Return to PowerShell



Who is online

Users browsing this forum: No registered users and 5 guests