获取所有安全组中所有用户的列表 [英] Get the list of all users in all Security Groups
本文介绍了获取所有安全组中所有用户的列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试获取所有AD安全组(Windows 2008 R2)中的所有用户列表并导出到.CSV文件。有人会帮我使用PowerShell脚本吗?
I am trying to get the list of all users in all AD Security groups ( Windows 2008 R2) and export to .CSV file. Would someone help me with PowerShell script?
提前致谢
Tek-Nerd
推荐答案
secGroups = get-adgroup -filter * |
select-object -expandproperty DistinguishedName |
sort-object
& {
foreach(
secGroups = get-adgroup -filter * | select-object -expandproperty DistinguishedName | sort-object & { foreach (
secGroup in
secGroup in
这篇关于获取所有安全组中所有用户的列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文