Windows Server โ€ข Quick Reference

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.

โฑ๏ธ 9 min reference๐ŸŸข Beginner โ†’ SysAdmin๐Ÿ“… Updated: 2026

AD Logical Hierarchy

Active Directory organizes every user, computer, and policy in a strict top-down tree: Forest โ†’ Domain โ†’ Organizational Unit (OU) โ†’ Objects.

FOREST (Security Boundary) corp.example.com DOMAIN (Replication Boundary) CORP\ (DNS + Auth + GPOs) GPO LINKED AT DOMAIN Password & Lockout Policy OU: IT-Admins Users + Workstations OU: Sales-Dept Users + Laptops GPO INHERITANCE โ†“ Flows down to child OUs GPOs flow top-down: Domain policies apply to all OUs unless overridden by a child OU GPO

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 *
Inspect all attributes of a user Shows Enabled, LockedOut, LastLogonDate, PasswordLastSet, and group memberships.
Get-ADComputer -Filter * -Properties OperatingSystem | Select Name, OperatingSystem
List all domain computers & OS versions Great for auditing outdated Windows builds or finding stale machines.
Get-ADGroupMember -Identity "Domain Admins" -Recursive
List all members of an AD group -Recursive expands nested groups so no hidden admin account slips through.
Unlock-ADAccount -Identity jdoe
Unlock a locked-out user account Fastest helpdesk fix after a user enters the wrong password too many times.
Search-ADAccount -LockedOut | Select Name, SamAccountName
Find every currently locked-out account Also supports -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.

1st Applied L โ€” Local Local Computer Policy (gpedit.msc)
2nd Applied S โ€” Site AD Site-level GPOs (physical location)
3rd Applied D โ€” Domain Domain-wide GPOs (e.g., Password Policy)
4th (Wins!) OU โ€” Org Unit Parent OU โ†’ Child OU (most specific wins)
Memory Trick: Remember "L-S-D-O-U โ€” Last Applied Wins!" An OU policy overrides Domain, Domain overrides Site, and Site overrides Local (unless a higher GPO has Enforced turned on).
gpupdate /force
Immediately refresh all Computer & User GPOs By default, clients refresh GPOs every ~90 minutes. Use /force to reapply everything now.
gpresult /r
Show Resultant Set of Policy (RSoP) summary Lists which GPOs were applied (and which were filtered/denied) in the terminal.
gpresult /h C:\Temp\gpo-report.html
Export a full HTML GPO diagnostic report Opens in any browser with exact winning GPO names, link locations, and WMI filter results.

3 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
Run full Domain Controller health diagnostics Tests DNS, SYSVOL, Netlogon, Kerberos, and replication. Add /q to show errors only.
repadmin /replsummary
Quick replication health summary across all DCs Look for 0 failures and low delta times. Any non-zero error count needs immediate attention.
nltest /dsgetdc:corp.example.com
Verify which DC & AD Site a client is using Confirms DNS SRV records resolve properly and shows whether the DC is a Global Catalog / PDC.
netdom query fsmo
Show which Domain Controllers hold the 5 FSMO roles Run before demoting or shutting down any Domain Controller!

4 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

โš ๏ธ Stop & Think Before Making These AD Changes
1. Creating OUs without "Protect object from accidental deletion"

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).

2. Clicking "Block Inheritance" on an OU carelessly

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.

3. Modifying the "Default Domain Policy" directly for everyday settings

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.