New version of get-GPOBackup

a4e4374871e047fca72fd693d24bd980 New version of get-GPOBackup 2

It has once again reached me a feature desire, and here is the implementation. With version 1.58 the group policy templates can be saved from the central store. This is especially good when importing new templates that may be buggy. This even happens to Microsoft with the German translations for Windows 10 times quite often. If you don’t know the script yet, I recommend having a look at the article: “Gruppenrichtlinien richtig sichern und dokumentieren“.

The new parameter is a switch called “PolicyDefinition”. To use the new feature, simply append “-PolicyDefinition”. The script creates a zip file of the central GPO memory. For me with my many templates, this is about 3 MB more per backup. Administrative permissions are not required for this feature.

Where can I get the new version?

As always either via the TechNet Gallery (short link:, here I am happy about a vote if you like the script. Alternatively, it can also be found in the PowerShell Gallery and can (if the PowerShell Gallery is attached) be viewed with a simple

Install-Script get-gpoBackup

can be installed, or with

Update-Script get-gpobackup

can be updated.

Wishes, suggestions or errors?

Just a comment, a mail or a comment at one of the two galleries. If the wish is plausible and I have time, I will install it.

Questions and answers

Also, I use this opportunity to publish a question, or better the answer to it: What is the best way to set up the GPO backup?

Short answer: Easy.

In-depth: Best as a scheduled task on a computer with PowerShell Active Directory and Group Policy modules. I just use a domain controller. I run the script once a day.

Setup for convenience, like me (installation via the PowerShell Gallery with default path), please customize to your environment, otherwise, this will not work:

Schtasks /create /RU "Administrator" /RP "password" /SC DAILY /TN "GPO-Backup" /TR "powershell.exe -WindowStyle hidden -ExecutionPolicy Bypass -nologo -noprofile get-GPOBackup.ps1 -BackupPath c:\GPOBackup -KeepDate 90 -PolicyDefinitions" /ST 06:06 /ET 08:00
031219 1705 NeueVersion1 New version of get-GPOBackup 4

Note about program and Power Shell Code

The code contained here serves as an example. I do not assume any warranty, guarantee or support for the code or its components. Use the code at your own risk.

I always recommend to have a close look at the scripts before using them.

This article first appeared on in German.

This article is a translation of the article “Neue Version von get-GPOBackup” (Published – 2019-03-14). Links may refer to other articles, these may also be available in English language.

Also it can be, that I still use screenshots of German systems. However, where it is possible for me with little effort, I insert screenshots of English systems.