The example scripts in the NetIQ Group Policy Administrator (GPA) 4.0 User Guide are incorrect, miss (NETIQKB38150)

  • 7738150
  • 02-Feb-2007
  • 28-Sep-2007

Resolution

fact
NetIQ Group Policy Administrator 4.0

symptom
The example scripts in the NetIQ Group Policy Administrator (GPA) 4.0 User Guide are incorrect, missing parameters, and/or do not work.

symptom
The Import and Backup example scripts in the NetIQ Group Policy Administrator (GPA) 4.0 User Guide are incorrect and missing parameters.

cause
The example scripts in the NetIQ Group Policy Administrator (GPA) 4.0 User Guide do not contain all the necessary parameters. 

fix

Below are the correct scripting examples for backup, import, restore and report generation operations in NetIQ Group Policy Administrator (GPA) 4.0.  These examples will be incorporated into the documentation included with the next release of GPA:

Backup Script Example 

REM **** BACKUP ********************************************************

dim x

set x = CreateObject("GPExplorer.PolicyManager.1")

REM ***** BackupPolicy(GPO LDAP path, Backup folder path, Domain, DC, comment, options)

x.BackupPolicy "LDAP://CHLD.PRNT.net/CN={2FC79BD5-2288-4C37-9BAF-49E6F8D21A17},CN=Policies,CN=System,DC=CHLD,DC=PRNT,DC=net", "C:\GPO Backups",  "chld.prnt.net", "chld-dc-01.chld.prnt.net","Backup from Scripts", 1

set x = nothing

Wscript.Echo "Backup Completed !"

REM *********************************************************************

 

Import Script Example 

REM ****** Import (use RestorePolicy) ***********************************

dim x , a

set x = CreateObject("GPExplorer.PolicyManager.1")

REM ***** RestorePolicy(GPO LDAP path, Backup folder path, Domain, DestDC, options)

x.RestorePolicy "LDAP://CHLD.PRNT.net/CN={FC53832A-7AB2-4100-A971-C3AEB48A645D},CN=Policies,CN=System,DC=CHLD,DC=PRNT,DC=net", "C:\GPO Backups\{79ED2956-3F25-43B4-AD8C-513CB850731A}",  "chld.prnt.net", "chld-dc-01.chld.prnt.net",  1

set x = nothing

Wscript.Echo "Import Completed"

REM *********************************************************************

 

Restore Script Example 


REM **** Restore ********************************************************

dim x , a

set x = CreateObject("GPExplorer.PolicyManager.1")

REM ***** RestorePolicy(Backup folder path, Domain, DestDC, options)

x.RestorePolicy ,"E:\GPO Backups\Backup Scripts\Backups\{33A49A2C-6A2A-45D1-B7CE-A8AEC3A3C325}",  "child-domain.com", "devel-child.child-domain.com",  1

set x = nothing

Wscript.Echo "Restore Completed"

REM *********************************************************************

 

Report Generation Script Example 


REM *********************************************************************

dim x

set x = CreateObject("GPExplorer.PolicyManager.1")

REM ***** GenerateReport(GPO LDAP path, output file path, options)

x.GenerateReport"LDAP://devel-child.child-domain.com/CN={31B2F340-016D-11D2-945F-00C04FB984F9},CN=Policies,CN=System,DC=child-domain,DC=com", "E:\GPO Backups\Backup Scripts\Reports\Report.htm", 0

set x = nothing

Wscript.Echo "Report Generation Completed"

REM *********************************************************************

 



Additional Information

Formerly known as NETIQKB38150

Feedback service temporarily unavailable. For content questions or problems, please contact Support.