Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Export members of an Active Directory Security Group using PowerShell

Posted on 2009-05-13
2
Medium Priority
?
7,441 Views
Last Modified: 2012-05-06
Hello,

I would like to export the members of one security group to a csv file from a WIndows Server 2003 Active Directory using PowerShell.

Please help.

Thanks
0
Comment
Question by:maherusa
2 Comments
 
LVL 17

Accepted Solution

by:
OriNetworks earned 1000 total points
ID: 24382005
There are free cmdlets available from quest to list users. check out this page http://dmitrysotnikov.wordpress.com/2007/04/18/powershell-for-active-directory-examples/
0
 
LVL 57

Assisted Solution

by:Mike Kline
Mike Kline earned 1000 total points
ID: 24382234
Yeah quest's cmdlets would do it

http://www.quest.com/activeroles-server/arms.aspx
I'm assuming you already have powershell installed since you asked the question, but in case someone comes across this from google you can get it here http://www.microsoft.com/windowsserver2003/technologies/management/powershell/download.mspx


use the Get-QADGroupmember cmdlet
So example -- I'll export the members of the domain admins group and export their samaccountname and name attribute and send the csv to the c drive

Get-QADGroupMember "domain admins" | Select-Object samaccountname, name | Export-CSV -path "c:\domain Admins.csv" -notypeinformation
Thanks
Mike

 
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

Had a business requirement to store the mobile number in an environmental variable. This is just a quick article on how this was done.
Let's recap what we learned from yesterday's Skyport Systems webinar.
This video shows how to use Hyena, from SystemTools Software, to bulk import 100 user accounts from an external text file. View in 1080p for best video quality.
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…
Suggested Courses

971 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