Skip to main content
< All Topics
Print

Clean a disorganized Domain Default Domain Policy

Automating Policy Cleanup & Reset

  • Reset to Default (Recommended): Use dcgpofix /target:both to restore both the Default Domain Policy and Default Domain Controller Policy to their default settings.
    • Automation Note: This command requires confirmation. While dcgpofix itself is a CLI tool that can be used in scripts, it is designed for manual restoration of the default state.
  • Remove Unlinked GPOs (Cleanup): Use PowerShell to find and delete GPOs that are not linked to any site, domain, or Organizational Unit (OU), reducing clutter.
  • Removing Specific Policies: If non-standard policies have been added to the DDP, the best practice is to remove those specific settings, rather than deleting the GPO itself, which can damage the domain structure.
  • Alternative Cleanup Tool: Utilize third-party PowerShell modules like CleanupMonster for automating the removal of unused or disabled Active Directory GPOs

Important Considerations

  • Backup Before Automating: Always back up Active Directory and Group Policies before executing any cleanup scripts or dcgpofix.
  • DO NOT Delete DDP: The Default Domain Policy should not be deleted, only restored to its default settings if modified, as it holds essential password/lockout policies.
  • Targeted Changes: If the DDP is overriding other policies, consider modifying the policy precedence rather than clearing the entire policy.