Announcement

Collapse
No announcement yet.

To set up a account policy in AD to disable every account not used more then 3 months

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • To set up a account policy in AD to disable every account not used more then 3 months

    Hi Team,

    How to set up a auto account policy in AD to disable every account not used more then 3 months.

    Thanks and Regards,
    Chigurusetty

  • #2
    Re: To set up a account policy in AD to disable every account not used more then 3 mo

    http://www.google.co.uk/#sclient=psy...gc.r_pw.&cad=b should give you some hints
    Script it as a scheduled task
    Tom Jones
    MCT, MCSE (2000:Security & 2003), MCSA:Security & Messaging, MCDBA, MCDST, MCITP(EA, EMA, SA, EDA, ES, CS), MCTS, MCP, Sec+
    PhD, MSc, FIAP, MIITT
    IT Trainer / Consultant
    Ossian Ltd
    Scotland

    ** Remember to give credit where credit is due and leave reputation points where appropriate **

    Comment


    • #3
      Re: To set up a account policy in AD to disable every account not used more then 3 mo

      Thanks for giving a clue to run....

      I got the simple steps to this task are below...

      Step 1: Detecting Inactive Users
      -------------------------------------------------
      You can run the following command at a Command Prompt:

      dsquery user -inactive 4 >c:\InactiveUsers.txt

      This command will detect the inactive users and export them to the file
      "c:\InactiveUsers.txt".

      Note: I assume you need to determine the users that haven't logged on for 4 weeks.
      Please change it accordingly.

      Step 2: Examine the list
      ------------------------------------
      Use the Notepad to open the c:\InactiveUsers.txt and remove those accounts that you
      don't want to disable.

      Step 3: Disabling Inactive Users
      ------------------------------------------------
      Run the following command:

      type c:\InactiveUsers.txt|dsmod user -disabled yes

      This command line will utilize this file (c:\inactiveUsers.txt) to run dsmod
      utility to disable those Users accounts.

      Comment

      Working...
      X