Excluding Datastores from Backups

PowerShell script exchange

Excluding Datastores from Backups

Veeam Logoby ekisner » Tue Aug 21, 2012 8:57 pm

Been poking aruond at this for a little while, and although I'm very close, my progress has dwindled down to a stand-still.

I want to add a simple exclusion, of all VMs in a datastore - specifically, by excluding the datastore. Please don't mind my nesting, I prefer it when writing on-the-fly commands, over scripts with variables.

Remove-VBRJobObject -Job (Get-VBRJob -name "My Backup Job") -Objects (Find-VBRViDatastore -server (Get-VBRServer -name "vCenter.domain.com") -name "Datastore to exclude")

Unfortunately, Find-VBRViDatastore returns a CViDatastoreItem value, where Remove-VBRJobObject requires a CObjectInJob value.

Anyone have some insight? I must need a different command to return a datastore as a CObjectInJob, but I can't seem to find one.
ekisner
Expert
 
Posts: 131
Liked: 31 times
Joined: Thu Jul 26, 2012 8:04 pm
Full Name: Erik Kisner

Re: Excluding Datastores from Backups

Veeam Logoby ThomasMc » Tue Aug 21, 2012 10:39 pm

You could have a butchers over this to get the answer

http://vpowercli.wordpress.com/2012/01/ ... -in-a-job/
ThomasMc
Expert
 
Posts: 293
Liked: 17 times
Joined: Wed Apr 13, 2011 12:45 pm
Full Name: Thomas McConnell


Return to PowerShell



Who is online

Users browsing this forum: No registered users and 3 guests