Active Directory, Group Policy (GPO) & FSMO Cheat Sheet
Your desk-side survival guide for Windows Active Directory Domain Services (AD DS)โcovering PowerShell user management, GPO inheritance, domain controller health checks, and the 5 FSMO roles.
AD Logical Hierarchy
Active Directory organizes every user, computer, and policy in a strict top-down tree: Forest โ Domain โ Organizational Unit (OU) โ Objects.
Figure 1: Active Directory logical tree โ Forests contain Domains, Domains contain OUs, and GPOs inherit downward.
1 AD PowerShell Cmdlets
Run these in an elevated PowerShell session on a Domain Controller or a workstation with RSAT installed (Import-Module ActiveDirectory).
Get-ADUser -Identity jdoe -Properties *Enabled, LockedOut, LastLogonDate, PasswordLastSet, and group memberships.
Get-ADComputer -Filter * -Properties OperatingSystem | Select Name, OperatingSystemGet-ADGroupMember -Identity "Domain Admins" -Recursive-Recursive expands nested groups so no hidden admin account slips through.
Unlock-ADAccount -Identity jdoeSearch-ADAccount -LockedOut | Select Name, SamAccountName-AccountDisabled, -PasswordExpired, or -AccountInactive -TimeSpan 90.00:00:00.
2 Group Policy CLI & Processing Order (LSDOU)
Windows applies Group Policy Objects in a fixed 4-step order called LSDOU. If two GPOs conflict on the same setting, the last one applied wins.
gpedit.msc)
gpupdate /force/force to reapply everything now.
gpresult /rgpresult /h C:\Temp\gpo-report.html3 AD Health, DNS & Replication CLI
When logins slow down, GPOs stop applying, or users see stale passwords on one branch office, run these built-in Domain Controller diagnostics.
dcdiag /v/q to show errors only.
repadmin /replsummary0 failures and low delta times. Any non-zero error count needs immediate attention.
nltest /dsgetdc:corp.example.comnetdom query fsmo4 The 5 FSMO Roles Quick Table
Active Directory is multi-master for everyday changes, but 5 special roles (Flexible Single Master Operations) can only be held by one Domain Controller at a time to prevent conflicts.
| FSMO Role | Scope | What It Does & What Breaks If It's Down |
|---|---|---|
| 1. Schema Master | Forest-wide (1) | Controls updates to the AD database blueprint (e.g., installing Exchange or upgrading AD schema). Daily logins still work if offline. |
| 2. Domain Naming Master | Forest-wide (1) | Approves adding or removing domains/application partitions in the forest. Prevents duplicate domain names. |
| 3. PDC Emulator | Domain-wide | Most critical day-to-day role: authoritative time sync (NTP), password changes, account lockouts, and GPO editing. |
| 4. RID Master | Domain-wide | Hands out pools of Relative IDs (RIDs) to DCs so every new user/group/computer gets a unique SID. |
| 5. Infrastructure Master | Domain-wide | Updates cross-domain group references (SID/DN changes). Tip: Do not place on a Global Catalog unless all DCs are GCs. |
5 Danger Zone: AD & GPO Mistakes to Avoid
Deleting an OU deletes every user, computer, and GPO link inside it. Keep Accidental Deletion protection checked on all OUs (and enable the AD Recycle Bin in AD Administrative Center).
Blocking inheritance stops parent Domain GPOsโincluding baseline security, firewall, BitLocker, and Defender policiesโfrom reaching those machines, leaving them exposed unless you re-link critical GPOs.
Keep the Default Domain Policy strictly for domain-wide Password, Account Lockout, and Kerberos rules. Always create a new, clearly named GPO for drive mappings, software, or desktop restrictions.