Command
Remove-GPOZaurrFolders
Removes specified GPOZaurr folders and backs them up to a specified path.
Syntax
Remove-GPOZaurrFolders [-BackupDated] [[-BackupPath] <String>] [[-ExcludeDomains] <String[]>] [[-ExtendedForestInformation] <IDictionary>] [[-FolderName] <String[]>] [-FolderType] <NTFRS|Empty> [[-Forest] <String>] [[-IncludeDomains] <String[]>] [[-LimitProcessing] <Int32>] [[-Type] <All|Netlogon|Sysvol>] [<CommonParameters>]#Parameter set:
All Parameter SetsDescription
This function removes specified GPOZaurr folders based on the provided criteria and backs them up to a specified path. It allows for filtering by folder type, domain, and other parameters.
Examples
EXAMPLE 1
Remove-GPOZaurrFolders -BackupPath "C:\Backups" -BackupDated -Type 'All' -FolderType 'NTFRS' -FolderName "Folder1" -LimitProcessing 10 -Forest "ExampleForest" -ExcludeDomains "Domain1" -IncludeDomains "Domain2" -ExtendedForestInformation $info
Removes GPOZaurr folders of type 'NTFRS' named "Folder1" from all domains in the forest "ExampleForest", backs them up to "C:\Backups" with a timestamp, and limits processing to 10 folders.Parameters
- -BackupDated SwitchParameter
- Indicates whether the backup path should include a timestamp.
- -BackupPath String
- The path where the GPOZaurr folders will be backed up.
- -ExcludeDomains String[]
- Specifies domains to exclude from processing.
- -ExtendedForestInformation IDictionary
- Specifies additional forest information.
- -FolderName String[]
- Specifies the name of the folder to remove.
- -FolderType String
- Specifies the type of folders to remove. Options are 'NTFRS' or 'Empty'.
- Possible values:
NTFRS,Empty - -Forest String
- Specifies the forest to target.
- -IncludeDomains String[]
- Specifies domains to include in processing.
- -LimitProcessing Int32
- Limits the number of folders to process.
- -Type String[]
- Specifies the type of folders to remove. Options are 'All', 'Netlogon', or 'Sysvol'.
- Possible values:
All,Netlogon,Sysvol
Common Parameters
This command supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
For more information, see about_CommonParameters.