account lockout issues

How to create 1 million OU’s and linked GPO’s using PowerShell:

Credential Roaming and NTDS.dit bloat:

What is logged to the Userenv.log file?

to track user logon/logoff

Step 1: Create the following two files using Notepad or your favorite text editor:

echo logon %username% %computername% %date% %time% >> \\sbs\share\logon.log

echo logoff %username% %computername% %date% %time% >> \\sbs\share\logon.log

Step 2: Update Group Policy to run the appropriate batch file. In Group Policy, go to:
User Configuration-> Windows Settings-> Scripts (Logon/Logoff)-> Logon

Step 3: As users log on and off, your log file should look something like this:

logon June VSXP Tue 22/02/2005 10:39:51.12
logoff June VSXP Tue 22/02/2005 10:41:08.45
logon MickM VSXP Tue 22/02/2005 10:42:01.07
logoff MickM VSXP Tue 22/02/2005 10:42:46.81

Powershell method:



List all SPNs Used

dsquery * “ou=domain controllers,dc=abgplanet,dc=abg,dc=com”  -filter “(&(objectcategory=computer)(servicePrincipalName=*))” -attr distinguishedName servicePrincipalName > spns.txt

PS script:

What are the DISM cmdlets?
%d bloggers like this: