PowerShell script exchange
Post Reply
ashuP
Lurker
Posts: 2
Liked: never
Joined: May 21, 2013 3:43 pm
Full Name: AshuP
Contact:

Disk configuration

Post by ashuP » May 21, 2013 4:02 pm

Hello, new to Veeam powershell...Has anyone come up with a script to list all the local drives that are included in the backup jops? We have few jobs which contain several servers and wanted to check which disk(s) are selected in the backup. I did the get-vbrjob | export-csv but that doesn't give me the info I am looking for....anyone por favor?

veremin
Product Manager
Posts: 17078
Liked: 1475 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Disk configuration

Post by veremin » May 22, 2013 8:24 am

Providing I’ve understood you correctly, the following script should answer your requirements:

Code: Select all

asnp VeeamPSSnapin
Get-VBRJob -name "Name of your Job" | Get-VBRJobObject | Select-Object -Property @{N="Name";E={$_.Name}} ,@{N="Included disks";E={$_.DiskFilter}}| Sort Name -Descending | Format-Table 
It lists all VMs that are backed up within a given job and also DiskFilter options for this VMs. All disks are enumerated one by one, so if you want to match SCSI (0:0) then it should be 2000 and so on:

Code: Select all

SCSI (0:1) - 2001
SCSI (0:2) - 2002 
...
SCSI (1:0) - 2015
Hope this helps.
Thanks.

ashuP
Lurker
Posts: 2
Liked: never
Joined: May 21, 2013 3:43 pm
Full Name: AshuP
Contact:

Re: Disk configuration

Post by ashuP » May 23, 2013 8:08 pm

Thank you very much v.Eremin, that gave me what I was looking for.

veremin
Product Manager
Posts: 17078
Liked: 1475 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Disk configuration

Post by veremin » May 24, 2013 8:02 am

Glad to hear that I was able to help.

Should any additional questions arise, don’t hesitate to let me know. Thanks.

Post Reply

Who is online

Users browsing this forum: Google [Bot] and 2 guests