Connect to remote Veeam Backup server with powershell

PowerShell script exchange

Connect to remote Veeam Backup server with powershell

Veeam Logoby pizzim13 » Tue May 10, 2011 6:19 pm

Is there a powershell cmdlet to remotely connect to a Veeam server?
pizzim13
Enthusiast
 
Posts: 86
Liked: 6 times
Joined: Thu Apr 21, 2011 7:37 pm

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Gostev » Tue May 10, 2011 6:46 pm

AFAIK PowerShell 2.0 supports remote operations (this has nothing to do with Veeam though).
Gostev
Veeam Software
 
Posts: 21385
Liked: 2348 times
Joined: Sun Jan 01, 2006 1:01 am
Location: Baar, Switzerland

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby a.fokkema » Mon May 16, 2011 10:50 am

@Gostev, Is it possible to add the cmdlet to the upcoming release of Veeam B&R?
a.fokkema
Influencer
 
Posts: 13
Liked: never
Joined: Wed Mar 30, 2011 2:06 pm
Full Name: Arne Fokkema

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Gostev » Mon May 16, 2011 5:16 pm

What cmdlet?
Gostev
Veeam Software
 
Posts: 21385
Liked: 2348 times
Joined: Sun Jan 01, 2006 1:01 am
Location: Baar, Switzerland

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby gvinpin » Tue May 17, 2011 10:09 pm

I would suggest that Veeam need to have a manual for PowerShell and PS remote connection.
It is a gray area, and many of enterprise customers have to raise a support calls for a simple script.
I will talk to my sales rep about it.
gvinpin
Enthusiast
 
Posts: 48
Liked: never
Joined: Sun Jan 01, 2006 1:01 am

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Alexey D. » Wed May 18, 2011 8:50 am

Hello,

There is a section devoted to PowerShell usage, in the User Guide and a help file shipped with B&R console (available through Help -> Help menu item). It also includes information on Veeam PowerShell remoting. Does it help you?
Alexey D.
 

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby a.fokkema » Tue May 24, 2011 5:45 pm

Gostev wrote:What cmdlet?


Like the VMware PowerCLI cmdlet connect-viserver to connect with the vCenter Server or a vSphere host. It would be awsome to work with Powershell without the use of Remoting.
a.fokkema
Influencer
 
Posts: 13
Liked: never
Joined: Wed Mar 30, 2011 2:06 pm
Full Name: Arne Fokkema

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Gostev » Tue May 24, 2011 5:53 pm

Hmm... but what's wrong with remoting? Available today, and does the job.
Gostev
Veeam Software
 
Posts: 21385
Liked: 2348 times
Joined: Sun Jan 01, 2006 1:01 am
Location: Baar, Switzerland

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby a.fokkema » Fri Aug 05, 2011 12:07 pm

It does the job indeed but with some limitations.
a.fokkema
Influencer
 
Posts: 13
Liked: never
Joined: Wed Mar 30, 2011 2:06 pm
Full Name: Arne Fokkema

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Sethbartlett » Fri Aug 05, 2011 4:13 pm

What limitations? There is a memory limitation for each remote powershell that is created, which is set to 120MB I believe by default, but this can be increased to whatever number you need. After remoting in, I don't see what other limitations will hold you back from using our powershell cmdlets.
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.
Sethbartlett
Expert
 
Posts: 282
Liked: 25 times
Joined: Wed Nov 10, 2010 6:51 pm
Full Name: Seth Bartlett

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby Gostev » Fri Aug 05, 2011 4:22 pm

LOL. I actually expected to see the wrath from our PowerShell guru when he sees that... and here it comes :mrgreen:
Gostev
Veeam Software
 
Posts: 21385
Liked: 2348 times
Joined: Sun Jan 01, 2006 1:01 am
Location: Baar, Switzerland

Load Veeam Module Remotely

Veeam Logoby tankbusta » Thu Dec 01, 2011 11:04 pm

[merged]

Is anyone using WindowsRM to query Powershell/Veeam remotely? I am trying to figure out the best way to get the Veeam Module imported.

I've tried creating a profile for everyone that has the module imported and that works on the server itself but it doesn't seem to work on a remote runspace. I also tried executing Import-Module "C:\...\Veeam.Backup.Powershell.dll" but that does not work either...
tankbusta
Lurker
 
Posts: 1
Liked: never
Joined: Sat Jan 22, 2011 4:57 pm
Full Name: Christopher Schmitt

Re: Load Veeam Module Remotely

Veeam Logoby ThomasMc » Fri Dec 02, 2011 9:24 am

tankbusta wrote:Is anyone using WindowsRM to query Powershell/Veeam remotely? I am trying to figure out the best way to get the Veeam Module imported.

I've tried creating a profile for everyone that has the module imported and that works on the server itself but it doesn't seem to work on a remote runspace. I also tried executing Import-Module "C:\...\Veeam.Backup.Powershell.dll" but that does not work either...


Once your connected to your veeam server just do

Code: Select all
asnp "VeeamPSSnapIn"
ThomasMc
Expert
 
Posts: 293
Liked: 17 times
Joined: Wed Apr 13, 2011 12:45 pm
Full Name: Thomas McConnell

Re: Connect to remote Veeam Backup server with powershell

Veeam Logoby jteager » Tue Dec 06, 2011 11:00 pm

Best way to do it in my experience is to use
Code: Select all
Invoke-Command -ComputerName "VBR-01" -ScriptBlock "asnp VeeamPSSnapin; #some code, using semicolons instead of line breaks#"


Nice thing with that as well is that if you're converting the data to a native powershell format (as opposed to the Veeam objects) you can do all the actual manipulation on the local side by returning the hash/array/string/what-have-you.
jteager
Veeam Software
 
Posts: 10
Liked: never
Joined: Mon Mar 28, 2011 2:13 pm
Full Name: Justin Teager


Return to PowerShell



Who is online

Users browsing this forum: No registered users and 7 guests