Solved

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

Posted on 2014-04-14
10
106,112 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
Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

 
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
5
 
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
3

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

The article will show you how you can maintain a simple logfile of all Startup and Shutdown events on Windows servers and desktops with PowerShell. The script can be easily adapted into doing more like gracefully silencing/updating your monitoring s…
Restoring deleted objects in Active Directory has been a standard feature in Active Directory for many years, yet some admins may not know what is available.
This tutorial will walk an individual through locating and launching the BEUtility application to properly change the service account username and\or password in situation where it may be necessary or where the password has been inadvertently change…
This tutorial will walk an individual through the steps necessary to join and promote the first Windows Server 2012 domain controller into an Active Directory environment running on Windows Server 2008. Determine the location of the FSMO roles by lo…

777 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