ccdc12
asked on
help with dsquery and dsget
I need help with the dsguery and dsget command.
I have an OU = Distro
inside of the OU there there is a Group scope that is = Universal
The group type is = Distribution
The group name is = ACL Team
This group has users object and contact object as the memebers of this distribution group.
I need information from this distribution group.
I need from the users in this group thier email address
I need from the contact object the email address
could you help me with this command and out put the result to a file.
I am missing the part how to get the information from the contacts in this distribution group
also let me know about the spaces in between the commands
Thanks
I have an OU = Distro
inside of the OU there there is a Group scope that is = Universal
The group type is = Distribution
The group name is = ACL Team
This group has users object and contact object as the memebers of this distribution group.
I need information from this distribution group.
I need from the users in this group thier email address
I need from the contact object the email address
could you help me with this command and out put the result to a file.
I am missing the part how to get the information from the contacts in this distribution group
also let me know about the spaces in between the commands
Thanks
dsquery group -name "ACL Team" | dsget group -members | dsget user -email -display > c:\Group\ACL.txt
ASKER
can a wild * be used?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
have u tried LDP? I believe it has a GUI as well
http://technet.microsoft.c om/en-us/l ibrary/cc7 72839.aspx
http://support.microsoft.com/kb/224543
http://technet.microsoft.c
http://support.microsoft.com/kb/224543
ASKER
I installed the powershell but I could not get the command posted above.
instead of trying to get the powershell command to work...
I am in a time crunch....
could you please provide the command that will work the quickest and easyest..
I have several groups to get who is the memeber and the emails and the contact email in each group
thanks
instead of trying to get the powershell command to work...
I am in a time crunch....
could you please provide the command that will work the quickest and easyest..
I have several groups to get who is the memeber and the emails and the contact email in each group
thanks
PowerShell is quickest and easiest for me to explain :)
Either run the version of PowerShell from the Quest Software folder in the Start Menu, or run this first:
Get-PSSnapIn -Reg | Add-PSSnapin -ea 0
It's likely that you're running the version without the additional commands added (because I didn't say you needed to do otherwise). Once you have those loaded the command should execute.
You can have it export directly to a CSV file by tacking Export-CSV onto the end:
Get-QADGroupMember "ACL Team" | Select-Object Name,Email | Export-CSV -Path "C:\Group\ACL.txt"
Otherwise you will need to construct queries like this for each group:
dsquery * -Filter "(&(objectClass=user)(obje
dsquery * -Filter "(&(objectClass=contact)(o
Chris
ASKER
dsget fail: CN= Name of Contact, OU=Glenwood,DC=com: The object clas of the target not match the one specified on the command line.
type line.
type dsget /? for help. Email
user@mail.com
When the distribution group has a contact object in with the user object I get this error.
If the distribution group only has user object I don't get an error
I think it is because I do not have the command to handle the contact object .
Thank