cancel
Showing results for 
Search instead for 
Did you mean: 

Using BEMCLI to make changes to globally excluded selections

pizzim13
Level 2

Does anyone have example code on how to make changes to globally excluded selections via powershell? I am looking to make date changes.

 

Capture1.PNG

Capture2.PNG

2 REPLIES 2

VJware
Level 6
Employee Accredited Certified

Afaik, you can set file objects excludes via BEMCLI, though not other parameters such as the "Files dated".

pizzim13
Level 2

You can, i.e.:

     $x = New-BEFileSystemSelection -FromDate (get-date).AddDays(-14) -ToDate (Get-Date) -Path                      "c:\temp\*.*"

     Get-BEBackupDefinition -Name 'exclude test' | Set-BEBackupDefinition -FileSystemSelection $x |
     Save-BEBackupDefinition -Confirm:$false

I just don't know how to set it globally.