programming4us
programming4us
DESKTOP

Windows Server 2008 and Windows Vista : Copying and Importing GPOs

- Free product key for windows 10
- Free Product Key for Microsoft office 365
- Malwarebytes Premium 3.7.1 Serial Keys (LifeTime) 2019

To efficiently utilize existing GPOs and their settings, you can use the copy and import features within the GPMC and the following scripts. The copy option allows a company to move GPOs efficiently from a test domain to a production domain, without having to manually duplicate the settings from one environment to the other.

1. CopyGPO.wsf

This script copies a GPO from one domain to another. This is ideal for moving GPOs from a test domain to production domain, or any other situation in which two domains need duplicate GPOs. If the GPO contains UNC paths or security principal references, the migration tables must be used to translate them from one domain to another.

Syntax
Usage: CopyGPO.wsf SourceGPO TargetGPO [/SourceDomain:value] [/TargetDomain:value]
[/SourceDC:value] [/TargetDC:value] [/MigrationTable:value] [/CopyACL]
SourceGPO: Name of the source GPO.
TargetGPO: Name of the target GPO.
SourceDomain: DNS name of the source domain.
TargetDomain: DNS name of the target domain.
SourceDC: Domain controller to use in the source domain.
TargetDC: Domain controller to use in the target domain.
MigrationTable: Migration table to use.
CopyACL: Copies the ACL on the GPO.


Example

This script copies the contents of GPO1 from the test.fabrikam.com domain and places the contents into GPO1 located in the production.fabrikam.com domain.

cscript CopyGPO.wsf GPO1 GPO1 /SourceDomain:test.fabrikam.com
/TargetDomain:production.fabrikam.com

2. ImportGPO.wsf

This script imports the settings from a backed-up GPO into an existing (target) GPO. If there is more than one version of the backed-up GPO, the latest is used. If you want to use a version other than the latest backed-up GPO for importing the settings, you must specify the Backup ID in the script. If you do not specify a target GPO, the target will be the name of the GPO backup. If a GPO exists with that name, the script imports the information into the existing GPO. If a GPO does not exist with that name, and you use the CreateIfNeeded switch, the script will create a new GPO in that name. You can use a migration table to handle any UNC paths or security principals must be translated during the import to the existing GPO.

Importing a GPO does not restore delegation information. To restore delegation information for a GPO, use the RestoreGPO.wsf script.

Syntax
Usage: ImportGPO.wsf BackupLocation BackupID [TargetGPO] [/MigrationTable:value]
[/CreateIfNeeded] [/Domain:value]
BackupLocation: File system location where the backup is located.
BackupID: GPO name or backup ID (GUID) of the backup to use.
TargetGPO: Target GPO in which to import settings.
MigrationTable: Optional migration table to use when importing.
CreateIfNeeded: Creates a new GPO if the specified target GPO does not exist.
Domain: DNS name of domain.


Example

This script takes the contents from the GPO with the specified GUID and copies them to a new GPO, named GPO1. The script specifies that the new GPO should be created if it does not already exist.

cscript ImportGPO.wsf \\Server1\gpo-backup {73624CC9-E8F2-4F05-88D2-193FAE8773CE} GPO1
/CreateIfNeeded


3. ImportAllGPO.wsf

This script creates a new GPO for every GPO that you have backed up in the reference backup location. The script uses only the latest version of the GPO from the backup location. The new GPO will maintain the same name as the GPO that you backed up. This script will not account for duplicate GPO names, so if there are existing target GPOs with the same name as those in the backup location, the script will overwrite the existing GPOs with the new GPO you are importing. Any settings you created in the existing GPO will be lost.

Syntax
Usage: ImportAllGPOs.wsf BackupLocation [/MigrationTable:value] [/Domain:value]
BackupLocation: File system location containing the GPO backups.
MigrationTable: Optional Migration table to use when importing.
Domain: DNS name of domain.


Example

This script takes all GPOs that have been archived to the gpo-backup share and imports the settings into existing (or new) GPOs, using the settings in the migration table named MigrationTable1.xml.

cscript ImportAllGPOs.wsf \\Server1\gpo-backup /MigrationTable:"G:\MigrationTable1.xml"				  
Other  
  •  Windows Server 2008 and Windows Vista : Backing Up and Restoring GPOs (part 2)
  •  Windows Server 2008 and Windows Vista : Backing Up and Restoring GPOs (part 1)
  •  Windows Small Business Server 2011 : Creating Custom Alerts - Creating an Alert for a Stopped Service, Custom Alert for Backup Failure
  •  Windows Small Business Server 2011 : Configuring Alerts - Alerts for Services, Performance Counter Alert, Event Log Error Alerts
  •  Windows Small Business Server 2011 : Network Reports (part 2) - Customizing the Detailed Network Report
  •  Windows Small Business Server 2011 : Network Reports (part 1) - Customizing the Summary Report
  •  Windows 8 : Diagnosis and Recovery - Windows Recovery Environment
  •  Windows 8 : Diagnosis and Recovery - Refresh and Reset
  •  Windows 8 : Diagnosis and Recovery - The Startup, Users, Details, and Services Tabs
  •  Windows Server 2008 R2 networking : Network Monitoring and Troubleshooting Utilities
  •  
    Top 10
    Free Mobile And Desktop Apps For Accessing Restricted Websites
    MASERATI QUATTROPORTE; DIESEL : Lure of Italian limos
    TOYOTA CAMRY 2; 2.5 : Camry now more comely
    KIA SORENTO 2.2CRDi : Fuel-sipping slugger
    How To Setup, Password Protect & Encrypt Wireless Internet Connection
    Emulate And Run iPad Apps On Windows, Mac OS X & Linux With iPadian
    Backup & Restore Game Progress From Any Game With SaveGameProgress
    Generate A Facebook Timeline Cover Using A Free App
    New App for Women ‘Remix’ Offers Fashion Advice & Style Tips
    SG50 Ferrari F12berlinetta : Prancing Horse for Lion City's 50th
    - Messages forwarded by Outlook rule go nowhere
    - Create and Deploy Windows 7 Image
    - How do I check to see if my exchange 2003 is an open relay? (not using a open relay tester tool online, but on the console)
    - Creating and using an unencrypted cookie in ASP.NET
    - Directories
    - Poor Performance on Sharepoint 2010 Server
    - SBS 2008 ~ The e-mail alias already exists...
    - Public to Private IP - DNS Changes
    - Send Email from Winform application
    - How to create a .mdb file from ms sql server database.......
    programming4us programming4us
    programming4us
     
     
    programming4us