Tag Archives: ad

Exporting Active Directory Users Into CSV

It took far too long to find this very very useful command online so I thought I’d repost to help others find it.
The below command exports as follows:
Connection to server: domain.local
Exporting attributes: whenChanged,whenCreated,cn,sAMAccountName,givenName,sn
From DN Root: DC=domain,DC=local
Into File: domain.local-users.csv
csvde -s domain.local -l "whenChanged,whenCreated,cn,sAMAccountName,givenName,sn" -d "DC=domain,DC=local" -f domain.local-users.csv