Command to find number of users in a domain (2003)

Hello

I need to find the actual number of users in our domain, how can i do that?

Thanks
srinivaskakumanuAsked:
Who is Participating?
 
Joseph DalyConnect With a Mentor Commented:
The quest cmdlets can be download on any desktop that has access to AD. They dont need to be downloaded on a server or anything.

The version depends on wether you have 32 or 64 bit os.

ActiveRoles Management Shell for Active Directory 32-bit
ActiveRoles Management Shell for Active Directory 64-bit
0
 
Joseph DalyCommented:
You can find the actual number of user accounts by running the following quest powershell command.

get-qaduser * -sizelimit 0 | Measure-Object | select-object count
0
The 14th Annual Expert Award Winners

The results are in! Meet the top members of our 2017 Expert Awards. Congratulations to all who qualified!

 
Joseph DalyCommented:
You can also do this using a saved query from within active directory users and computers.

Create a new custom query and paste the below in.

(&(objectCategory=user)(objectClass=user)
0
 
srinivaskakumanuAuthor Commented:
xxdcmast

I tried your Powershell cmd but it does not work
0
 
Joseph DalyCommented:
Do you have the quest cmdlets? If not download them from here.

http://www.quest.com/powershell/activeroles-server.aspx
0
 
GanparCommented:
dsquery * -filter "(&(objectCategory=person)(objectClass=user)(!userAccountControl:1.2.840.113556.1.4.803:=2))"

Please note userAccountControl:1.2.840.113556.1.4.803:=2 is for user who's account is enabled
0
 
srinivaskakumanuAuthor Commented:
xxdcmast

What version should I download. =Like I stated our Forest/Domain level is 2003. I do have a new server 2008 R2 added recently as a new DC. Should I install the quest software on it, if yes what version.
0
 
srinivaskakumanuAuthor Commented:
Thanks so much, it worked.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.