updating Active Directory user Logon Count attribute


  • Is the logon count attribute updated only when a user physically logs in to a workstation or Is threre Any way to update the attribute programatically or through script.Just asking for testing purposes.
    Thursday, December 29, 2016 9:43 AM


All replies

  • As far as I know, the attribute is owned by the system. Also, it is not replicated, so a different value for each user is maintained on each domain controller.

    Richard Mueller - MVP Enterprise Mobility (Identity and Access)

    • Proposed as answer by AlvwanModerator Friday, December 30, 2016 2:22 AM
    • Marked as answer by sinedd Wednesday, January 4, 2017 3:29 AM
    Thursday, December 29, 2016 1:01 PM
  • Well the thing that i clearly needed to know is that if we use an authentication api to validate an active directory user and password  against a domain controller does the logon count attribute get updated.
    Thursday, December 29, 2016 1:22 PM
  • As Richard mentioned, the attribute is owned by the system and only a DC can update it. I tried to use my script here ( to check a user credentials and the attribute value do not get incremented.

    This posting is provided AS IS with no warranties or guarantees , and confers no rights.

    Ahmed MALEK

    My Website Link

    My Linkedin Profile

    My MVP Profile

    Friday, December 30, 2016 1:31 AM
  • Hi,

    Just checking in to see if the information provided was helpful. Please let us know if you would like further assistance.

    Best Regards,

    Alvin Wang

    Please remember to mark the replies as answers if they help.
    If you have feedback for TechNet Subscriber Support, contact

    Tuesday, January 3, 2017 7:18 AM