Solved

How to export users list from AD security group in csv format?

Posted on 2014-04-14
10
109,882 Views
4 Endorsements
Last Modified: 2016-05-13
Hello there,

I have a AD security group with 500 members. What is the command to export the list in csv format ?

Please advise.

Thanks and Regards
4
Comment
Question by:goprasad
10 Comments
 
LVL 9

Assisted Solution

by:djsharma
djsharma earned 84 total points
ID: 39998401
Get-Process | Export-Csv c:\scripts\test.txt.

Refer the below link for proper explanation of Using the Export-Csv Cmdlet
http://technet.microsoft.com/en-us/library/ee176825.aspx
0
 
LVL 29

Assisted Solution

by:becraig
becraig earned 249 total points
ID: 39998403
If you have PowerShell ad modules installed
Run the below in a PowerShell window
Import-module ac*
Get-ADUser -filter *| Select-Object lastname,firstname,description | Export-Csv c:\Allusers.csv -NoTypeInformation
0
 
LVL 29

Assisted Solution

by:becraig
becraig earned 249 total points
ID: 39998406
If no PowerShell modules this should work

csvde -f allusers.csv -r "(&(objectClass=user)(objectCategory=person)"
0
Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

 
LVL 36

Accepted Solution

by:
Mahesh earned 84 total points
ID: 39998414
Try below

Try below

Import-Module ActiveDirectory
Get-ADGroupMember -identity “Name of Group” | select name | Export-csv -path
Import-Module ActiveDirectory
Get-ADGroupMember -identity “Name of Group” | select name | Export-csv -path C:\Output\Groupmembers.csv -NoTypeInformation

Open in new window


Just run powershell commands with elevated command prompt

This will give you exported output of all group members
6
 
LVL 29

Assisted Solution

by:becraig
becraig earned 249 total points
ID: 39998419
I  missed the part about this being for group members :(

Good catch.
0
 

Assisted Solution

by:OomWall
OomWall earned 83 total points
ID: 39998432
Hi
CSVDE

If you want a gui, use a LDAP browser like Softerra

You can also try powershell command Get-ADGroupMember and pipe it to a csv
e.g. Get-ADGroupMember administrators (much less painfull than csvde... and more fun)
0
 

Author Comment

by:goprasad
ID: 40000409
Please advise i have a AD group name Citrix group, where to place this in the command line?

Please advise
0
 

Author Comment

by:goprasad
ID: 40000417
Sorry I got the command working thanks very much.
0
 

Expert Comment

by:rajpalsidhu
ID: 40819336
Just used this command successfully.

Thanks for that.
0
 
LVL 6

Expert Comment

by:Sid_F
ID: 41592733
For anyone else looking up this query without powershell you can use
dsquery group -name "groupname" | dsget group -members >c:\groupmembers.csv
4

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Recently, I was assigned the task of performing a hardware refresh in the datacenter. The previous Windows 2008 systems were connected to the SAN via fiber channel HBA’s and among other thing, had PowerPath installed in order to provide sufficient f…
Possible fixes for Windows 7 and Windows Server 2008 updating problem. Solutions mentioned are from Microsoft themselves. I started a case with them from our Microsoft Silver Partner option to open a case and get direct support from Microsoft. If s…
To efficiently enable the rotation of USB drives for backups, storage pools need to be created. This way no matter which USB drive is installed, the backups will successfully write without any administrative intervention. Multiple USB devices need t…
This tutorial will walk an individual through the process of installing of Data Protection Manager on a server running Windows Server 2012 R2, including the prerequisites. Microsoft .Net 3.5 is required. To install this feature, go to Server Manager…

840 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question