Knowledge / Information Technology / Windows Server and Active Directory

Windows Server and Active Directory

Information Technology (B.E./B.Tech) · Networks and infrastructure · free study notes for exams, placements and interviews

In short

Windows Server is Microsoft's server operating system (current generally available release: Windows Server 2025, with 2019 and 2022 still widely deployed in India), and Active Directory Domain Services (AD DS) is its directory service — a hierarchical, replicated database of users, computers, groups and policies that provides centralised authentication (Kerberos), authorisation and configuration management. One sign-in to a domain gives a user access to file shares, printers, intranet apps and mail across the organisation, while administrators push settings to thousands of machines using Group Policy. This is the backbone of enterprise IT in Indian banks, PSUs, government departments, hospitals, manufacturing plants and every large IT services campus. It is examined in university papers on Network Operating Systems / System Administration and in AICTE-model network-administration labs, and it is the single most asked area in Indian system-administrator, desktop-support L2/L3 and cloud-infrastructure interviews (TCS, Infosys, Wipro, HCLTech, Cognizant, Capgemini, Accenture, LTIMindtree, Tech Mahindra).

Explained

Windows Server: editions, roles and installation options

Active Directory: logical structure

Physical structure, domain controllers and replication

How logon actually works: DNS, LDAP, Kerberos

  1. The client finds a DC by querying DNS for SRV records under _ldap._tcp.dc._msdcs.<domain> — hence the rule *AD cannot exist without correctly configured DNS*.
  2. Kerberos AS exchange: client sends a pre-authenticator timestamp encrypted with the password-derived key; the KDC (every DC) returns a TGT encrypted with the krbtgt key.
  3. TGS exchange: to reach a file server, the client presents the TGT and asks for a service ticket for that SPN; the ticket is encrypted with the service account's key.
  4. AP exchange: the client presents the service ticket to the server, which decrypts and reads the PAC (group SIDs) to build an access token.
  5. Authorisation then happens locally: the token's SIDs are compared against the DACL on the resource (NTFS/share permissions).
  6. Key ports: LDAP 389, LDAPS 636, Global Catalog 3268/3269, Kerberos 88, kpasswd 464, DNS 53, SMB 445, RPC endpoint mapper 135 plus a dynamic high range, WinRM 5985/5986.
  7. Time matters: Kerberos allows a default 5-minute clock skew; a DC whose clock drifts breaks logons. The PDC Emulator of the forest root is the authoritative NTP source.
  8. NTLM remains as a fallback (used with IP addresses, local accounts, workgroup access) but is challenge–response, lacks mutual authentication and is being phased out; auditing and then disabling NTLM is standard hardening.

Users, groups, permissions and delegation

Group Policy

Trusts, migration and the cloud relationship

Key points

Formulas and examples

Effective network permission = MIN(Share permission, NTFS effective permission)
NTFS effective permission = (union of all Allow permissions from user + all groups) − (any applicable Deny)
Number of automatic intra-forest trusts = (number of domains in forest) − 1
Connections in a full mesh of n DCs = n(n − 1)/2 — the reason KCC builds a ring with shortcut links instead
Maximum intra-site replication latency (3-hop ring rule) ≈ hops × notification delay, hops ≤ ⌊n/2⌋ for a ring of n DCs
RID pool: each DC gets 500 RIDs by default from the RID Master; DCs requested = ⌈accounts needed ÷ 500⌉ (approx.)
Site-link replication interval: default 180 minutes, configurable 15–10,080 minutes; cost default 100 (lower cost = preferred path)

Example 1 — Effective permissions. Ravi is in groups Finance and Interns. On share \\FS01\Accounts: share permission for Finance-Users = Change (≈ Modify). NTFS: Finance = Modify, Interns = Read, Interns = Deny Write.

Example 2 — GPO precedence. Settings for the "Screen saver timeout": Local = 30 min; Site GPO = 20 min; Domain GPO = 15 min; OU Sales GPO = 10 min; child OU Sales\Field GPO = 5 min. Block Inheritance is set on Sales, and the Domain GPO link is Enforced.

Example 3 — Trusts after an acquisition. abl.local forest has domains abl.local, hr.abl.local, plant.abl.local. It acquires forest nova.in with 2 domains.

Example 4 — Replication and RID planning. A campus has 6 DCs in one site and a branch with 1 RODC; the site link is default (180 min, cost 100). HR will create 2,300 new student accounts.

Example 5 — Licensing cost (illustrative). Two physical hosts, each 2 processors × 10 cores = 20 cores, running 6 VMs each, 400 staff needing user CALs.

AspectWorkgroupDomain (AD DS)
Account databaseLocal SAM on each PCCentral ntds.dit on DCs
Scale~10–20 machinesThousands
ManagementPer machineGroup Policy, central
AuthenticationNTLM, localKerberos, domain-wide SSO
Use in IndiaSmall shop, lab benchBank branch, plant, campus
FeatureAD DS (on-premises)Microsoft Entra ID (cloud)
StructureForest / domain / OU hierarchyFlat tenant with groups and admin units
ProtocolsLDAP, Kerberos, NTLMSAML, OAuth 2.0, OIDC, SCIM, Graph
Device policyGroup PolicyIntune / MDM, Conditional Access
ObjectsUsers, computers, GPOs, printersUsers, groups, app registrations, devices
Joined devicesDomain joinEntra join / hybrid join / registered
FSMO roleScopeWhat breaks if it is down
Schema MasterForestSchema extensions (e.g. Exchange setup)
Domain Naming MasterForestAdding/removing domains or app partitions
RID MasterDomainNew account creation once pools exhaust
PDC EmulatorDomainTime sync, lockout and password-change chaining, GPO editing
Infrastructure MasterDomainCross-domain reference cleanup (stale SIDs shown)
# Promote the first DC of a new forest
Install-WindowsFeature AD-Domain-Services -IncludeManagementTools
Install-ADDSForest -DomainName "abl.local" -DomainNetbiosName "ABL" `
  -InstallDns -DomainMode WinThreshold -ForestMode WinThreshold

# Create an OU, a user and a group; apply AGDLP
New-ADOrganizationalUnit -Name "Finance" -Path "DC=abl,DC=local"
New-ADUser -Name "Ravi Kumar" -SamAccountName ravi.kumar `
  -UserPrincipalName ravi.kumar@abl.local -Path "OU=Finance,DC=abl,DC=local" `
  -AccountPassword (Read-Host -AsSecureString "Password") -Enabled $true
New-ADGroup -Name "G-Finance-Staff"  -GroupScope Global      -Path "OU=Finance,DC=abl,DC=local"
New-ADGroup -Name "DL-Accounts-Modify" -GroupScope DomainLocal -Path "OU=Finance,DC=abl,DC=local"
Add-ADGroupMember -Identity "G-Finance-Staff"   -Members ravi.kumar
Add-ADGroupMember -Identity "DL-Accounts-Modify" -Members "G-Finance-Staff"

# Diagnose
dcdiag /v                      # DC health
repadmin /replsummary          # replication status
repadmin /showrepl
netdom query fsmo              # who holds which FSMO role
nltest /dsgetdc:abl.local      # which DC am I using
w32tm /query /status           # time source and skew
gpresult /r                    # applied GPOs for this user/computer
Get-ADUser ravi.kumar -Properties MemberOf, LastLogonDate, LockedOut

Where it is used

Interview questions

Common mistakes

Related topics

Open in the Knowledge reader →Find jobs →