User Tools

Site Tools


microsoft:activedirectory:scripting:powershell:grouppolicy

Microsoft - Active Directory - Scripting - Powershell - Group Policy

Export list of OUs with linked GPOs

Get-ADOrganizationalUnit -Filter * | `
Get-GPInheritance | `
Where-Object {$_.GpoLinks -ne $null} | `
Select-Object Path, @{Name = 'GpoLinks';Expression = {[string]::join(', ',$_.GpoLinks.DisplayName)}} | `
Sort-Object Path | `
Export-Csv -Delimiter ";" -NoTypeInformation -Path "C:\TEMP\result.csv"
microsoft/activedirectory/scripting/powershell/grouppolicy.txt · Last modified: 2019/11/06 11:44 by bas

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki