Set-VBRJobProxy Error ...

PowerShell script exchange

Set-VBRJobProxy Error ...

Veeam Logoby Jack1874 » Wed Nov 18, 2015 4:08 pm

Guys, trying to use the Set-VBRJobProxy command.. but getting the following error.

Is my syntax correct ...

get-VBRJob -Name 'TestJob01' | Set-VBRJobProxy -Proxy 'Proxy1'

I'm getting an error that tells me "cannot bind proxy parameter" . Cannot convert the 'Proxy1' value of type ...
Jack1874
Enthusiast
 
Posts: 88
Liked: 4 times
Joined: Sat Oct 17, 2015 3:32 pm
Location: Canada
Full Name: Stuart Little

Re: Set-VBRJobProxy Error ...

Veeam Logoby v.Eremin » Wed Nov 18, 2015 4:23 pm

Nope, the syntax is incorrect. You're trying to pass string value to the parameter that expects proxy entity. Check the following:

Code: Select all
Asnp VeeamPSSnapin
$Proxy = Get-VBRViProxy -Name "Name of proxy"
$Job = Get-VBRJob -Name "Name of job"
Set-VBRJobProxy -Job $Job -Proxy $Proxy


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

Re: Set-VBRJobProxy Error ...

Veeam Logoby Jack1874 » Wed Nov 18, 2015 10:37 pm

Excellent.. many thanks
Jack1874
Enthusiast
 
Posts: 88
Liked: 4 times
Joined: Sat Oct 17, 2015 3:32 pm
Location: Canada
Full Name: Stuart Little

Re: Set-VBRJobProxy Error ...

Veeam Logoby v.Eremin » Thu Nov 19, 2015 10:10 am

You're welcome.

Whenever you stumble upon PS-related issue, it might be a good idea to check our online help center first. Since existing commandlets, as well as, the parameters they accept are described there in quite precise way. Also, you can find there several examples.

Thanks.
v.Eremin
Veeam Software
 
Posts: 13266
Liked: 968 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 9 guests