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

x
?
Solved

dsget - the object class of the target does not match the one specified on the command line

Posted on 2013-01-14
2
Medium Priority
?
808 Views
Last Modified: 2013-02-28
Hi Guys,

When i run this command:

dsquery group -name "remoteaccessemployee" | dsget group -members -expand | dsget user -fn -ln > h:\remoteaccesseployee.txt

i get this error message the object class of the target does not match the one specified on the command line.

Please help!

Thanks,
k
0
Comment
Question by:chgl
2 Comments
 
LVL 80

Expert Comment

by:arnold
ID: 38775735
Your issue is that your dsquery is returning an empty list dsget group -members -expand has no information on which to get anything and is returning the error.  If the members expand also returns an empty set later on, you will get a similar error from the dsget user query.
0
 
LVL 29

Accepted Solution

by:
becraig earned 1500 total points
ID: 38776979
you probably want to run the dsquery on its own to see the result set returned.

Also remember you can wildcard dsquery  e.g. dsquery group -name "*remot*cc*s*"
0

Featured Post

Simplify Active Directory Administration

Administration of Active Directory does not have to be hard.  Too often what should be a simple task is made more difficult than it needs to be.The solution?  Hyena from SystemTools Software.  With ease-of-use as well as powerful importing and bulk updating capabilities.

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.
Windows 8 came with a dramatically different user interface known as Metro. Notably missing from that interface was a Start button and Start Menu. Microsoft responded to negative user feedback of the Metro interface, bringing back the Start button a…
Attackers love to prey on accounts that have privileges. Reducing privileged accounts and protecting privileged accounts therefore is paramount. Users, groups, and service accounts need to be protected to help protect the entire Active Directory …

916 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