locked
User CAL active count per domain RRS feed

  • Question

  • I have two domains and need to come up with a total list of active users on two domains. Seeing if anyone has anything powershell related that would put this into a csv please?
    Friday, August 2, 2019 3:09 PM

All replies

  • We do not supply scripts on request.

    Look in the Gallery for scripts.

    There is only one way to fi nd users and that is to count the accounts in AD that are active.


    \_(ツ)_/

    Friday, August 2, 2019 7:26 PM
  • Hi,

    Thanks for your question.

    Get domain's active ad users.

    Get-ADUser -Filter {Enabled -eq $true} -SearchBase "DC=test,DC=com"

    count ad users:

    (Get-ADUser -Filter {Enabled -eq $true} -SearchBase "DC=test,DC=com").count

    export to csv file:

    Get-ADUser -Filter {Enabled -eq $true} -SearchBase "DC=test,DC=com" | Export-Csv -Path "c:\test\users.csv"

    https://docs.microsoft.com/en-us/powershell/module/addsadministration/get-aduser?view=win10-ps

    Best regards,

    Lee


    Just do it.

    Monday, August 5, 2019 7:42 AM
  • Hi,

    Was your issue resolved?

    If you resolved it using our solution, please "mark it as answer" to help other community members find the helpful reply quickly.

    If you resolve it using your own solution, please share your experience and solution here. It will be very beneficial for other community members who have similar questions.

    If no, please reply and tell us the current situation in order to provide further help.

    Best Regards,

    Lee



    Just do it.

    Friday, September 6, 2019 12:54 PM