Forum Discussion

Jan Løbner Dam's avatar
Jan Løbner Dam
Copper Contributor
Nov 23, 2017
Solved

log search showing logged on users

Hi all.   I'm not sure if this is the right place to ask, but here goes.   I have been asked to make a dashboard showing the count of users currently logged in to our local ad.   I have t...
  • Meir_Mendelovich's avatar
    Nov 23, 2017

    Hi Jan,

     

     

    Is this what you are looking for:

    SecurityEvent

    | where EventID == 4624
    | where ( LogonTypeName == "3 - Network" )
    | where ( Computer == "ad server" )
    | where AccountType == "User"
    | summarize dcount(TargetAccount)

     

    ?

     

    It would show you total number of users that logged on to the server but not the number of users that are currently logged on.

    To do this, you need to left Join the list of users on the 4624 records with the list of users that have 4634 or 4647 records. Those that doesn't have a match are still logged on.

     

    Hope this helps,

    Meir :->

Resources