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 »

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: 20270
Liked: 2252 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Disk configuration

Post by veremin »

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 »

Thank you very much v.Eremin, that gave me what I was looking for.
veremin
Product Manager
Posts: 20270
Liked: 2252 times
Joined: Oct 26, 2012 3:28 pm
Full Name: Vladimir Eremin
Contact:

Re: Disk configuration

Post by veremin »

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: No registered users and 19 guests