05-14-2012 03:53 AM
In BE 2012, I want to create a backup job including multiple path using BEMCLI.
I tried the following steps.
BEMCLI>Get-BEBackupDefinition -Name "2K8R2 Backup00001"| Export-BEBackupDefinition > .\ExportedBackup01.ps1
BEMCLI>$p = New-BEFileSystemSelection -Path "D:\DataA\*"
BEMCLI>.\ExportedBackup01.ps1 2K8R2 -FileSystemSelection $p | Save-BEBackupDefinition
Solved! Go to Solution.
05-14-2012 07:09 PM
To quote the help for the filesystemselection parameter of the Set-BEBackupDefinition Cmdlet
To specify files or directories to include, specify one or more paths using commas to separate the values.
05-14-2012 07:09 PM
To quote the help for the filesystemselection parameter of the Set-BEBackupDefinition Cmdlet
To specify files or directories to include, specify one or more paths using commas to separate the values.
05-14-2012 08:48 PM
Thanks pkh,
I could create the backupjob what I want!
I really appreciated your help.
05-28-2012 06:13 AM
FYI
I did the following way last time.
$p = New-BEFileSystemSelection -Path "D:\DataA\*"
.\ExportedBackup01.ps1 2K8R2 -FileSystemSelection $p | Set-BEBackupDefinition -FileSytemSelection ”D:\DataB\*,D:\DataC\*” | Save-BEBackupDefinition
I found another way.
$p = @()
$p +=New-BEFileSystemSelection -Path "D:\DataA\*"
$p +=New-BEFileSystemSelection -Path "D:\DataB\*"
$p +=New-BEFileSystemSelection -Path "D:\DataB\*"