Solved

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

Posted on 2014-04-14
10
96,907 Views
3 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
3
Comment
Question by:goprasad
10 Comments
 
LVL 9

Assisted Solution

by:djsharma
djsharma earned 84 total points
Comment Utility
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 28

Assisted Solution

by:becraig
becraig earned 249 total points
Comment Utility
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 28

Assisted Solution

by:becraig
becraig earned 249 total points
Comment Utility
If no PowerShell modules this should work

csvde -f allusers.csv -r "(&(objectClass=user)(objectCategory=person)"
0
 
LVL 35

Accepted Solution

by:
Mahesh earned 84 total points
Comment Utility
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
3
 
LVL 28

Assisted Solution

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

Good catch.
0
How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

 

Assisted Solution

by:OomWall
OomWall earned 83 total points
Comment Utility
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
Comment Utility
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
Comment Utility
Sorry I got the command working thanks very much.
0
 

Expert Comment

by:rajpalsidhu
Comment Utility
Just used this command successfully.

Thanks for that.
0
 
LVL 5

Expert Comment

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

Featured Post

Complete Microsoft Windows PC® & Mac Backup

Backup and recovery solutions to protect all your PCs & Mac– on-premises or in remote locations. Acronis backs up entire PC or Mac with patented reliable disk imaging technology and you will be able to restore workstations to a new, dissimilar hardware in minutes.

Join & Write a Comment

You might have come across a situation when you have Exchange 2013 server in two different sites (Production and DR). After adding the Database copy in ECP console it displays Database copy status unknown for the DR exchange server. Issue is strange…
Sometimes drives fill up and we don't know why.  If you don't understand the best way to use the tools available, you may end up being stumped as to why your drive says it's not full when you have no space left!  Here's how you can find out...
This tutorial will walk an individual through the steps necessary to configure their installation of BackupExec 2012 to use network shared disk space. Verify that the path to the shared storage is valid and that data can be written to that location:…
This tutorial will walk an individual through the process of installing the necessary services and then configuring a Windows Server 2012 system as an iSCSI target. To install the necessary roles, go to Server Manager, and select Add Roles and Featu…

744 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

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now