Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
In organizations that use Active Directory, export of Active Directory objects is a frequent task for IT pros. With native tools, export of Active Directory objects to CSV means using a PowerShell script, which takes time. But with the right tool, IT admins can perform an export of AD objects to CSV and get a readable report in minutes.
- Open the Powershell ISE → Create a new script with the following code and run it.
Get-ADObject -Filter 'Name -like "*"' |
Where-Object {$_.ObjectClass -eq "user" -or $_.ObjectClass -eq "computer" -or $_.ObjectClass -eq "group" -or $_.ObjectClass -eq "organizationalUnit"} | Sort-Object ObjectClass | Export-CSV C:\Temp\ExportAD.csv -notypeinformation
- Open the file produced by the script in MS Excel.
- Report example:
https://img.netwrix.com/howtos/export_ad_2.png
Credits
Originally posted - https://www.netwrix.com/how_to_export_active_directory_objects_to_csv.html