06
Mar
09

Export Group policy on a network

computergeek

For Microsoft computer network without Active Directory, deploying Group Policy is a nightmare as you definitely don’t want to get into Group Policy Object Editor and edit the option one-by-one on each PC.

This an alternative way to do so:

1. Open %systemroot%\system32\grouppolicy\ (eg. c:\WINDOWS\system32\GroupPolicy\)

2.Copy both “machine” and “user” folders to the “%systemroot%\system32\grouppolicy” – folder (same location) on the target machine.

3. Reboot or a “gpupdate /force” command to refresh the group policy.

Hereby I provide an example of batch file to do such jobs in one click.

First, you need to have both “machine” and “user” folders stored under a folder named “GroupPolicySource” (any filename as you like). Locate the batch file as in same folder with “GroupPolicySource” folder.

Batch file:

xcopy GroupPolicySource c:\WINDOWS\system32\GroupPolicy\ /s /e /y
gpdupate /f

or

xcopy GroupPolicySource c:\WINDOWS\system32\GroupPolicy\ /s /e /y
shutdown -r -i 5 (reboot in 5 seconds)

Reference:

  1. Florian’s Blog: How can I export local Group Policy settings made in gpedit.msc?
  2. XCOPY command reference
Advertisements

0 Responses to “Export Group policy on a network”



  1. Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: