Skip to main content
Version: Next

Task 07: Configure Time Synchronization (NTP)

Runbook Azure Dell

DOCUMENT CATEGORY: Runbook SCOPE: Time synchronization PURPOSE: Configure w32tm with the NTP server from variables.yml so all cluster nodes synchronize to the same authoritative time source — required for Kerberos, Active Directory, and Arc registration MASTER REFERENCE: Phase 03: OS Configuration

Status: Active Estimated Time: 5 minutes per node / 10 minutes orchestrated (all nodes)


Overview

All Azure Local nodes must synchronize time from the same NTP source before AD domain join and Arc registration. Kerberos authentication fails when clock skew exceeds five minutes. This task configures the Windows Time service (w32tm) on each node, restarts the service, forces an immediate resync, and validates the resulting stratum.

What the scripts do:

  1. Hard-fail on any REPLACE placeholder remaining in #region CONFIGURATION
  2. Configure w32tm with the NTP server from active_directory.ntp_servers
  3. Restart the Windows Time service
  4. Force an immediate resync (w32tm /resync /force)
  5. Verify the resulting sync status and stratum — warn if stratum 16 (unsynchronized)

Prerequisites

RequirementDescriptionSource
Task 06 completeDNS client verified and functionalTask 06: Verify DNS
NTP server addressFQDN or IP of the authoritative NTP servervariables.yml: active_directory.ntp_servers
Local admin rightsRequired to restart Windows Time serviceNode credentials

Configuration Reference

variables.yml pathScript variableExample
active_directory.ntp_servers[0]$NTPServer10.100.10.1
cluster_nodes[].management_ipPSRemoting target (orchestrated only)10.100.200.11
cluster_nodes[].hostnameNode display name (orchestrated only)azlocal-node01
variables.yml — NTP server list

active_directory.ntp_servers is a YAML list. The direct script uses the primary (first) entry. The orchestrated script joins all entries as a space-separated manualpeerlist.


Execution Options

Run on each node individually — via RDP, console, or KVM.

Toolkit script: scripts/deploy/04-cluster-deployment/phase-03-os-configuration/task-07-configure-time-synchronization-ntp/powershell/Set-NTPConfiguration.ps1

Set $NTPServer to the first entry from active_directory.ntp_servers in variables.yml.

Set-NTPConfiguration.ps1
# -- Edit before running -------------------------------------------------
$NTPServer = "REPLACE_WITH_NTP_SERVER" # active_directory.ntp_servers[0]
# ------------------------------------------------------------------------

if ($NTPServer -match "^REPLACE_") { Write-Host "[ERROR] Set NTPServer before running" -ForegroundColor Red; exit 1 }

w32tm /config /manualpeerlist:$NTPServer /syncfromflags:manual /reliable:YES /update
Restart-Service w32time -Force
w32tm /resync /force
w32tm /query /status

Validation Checklist

  • NTP server configured on all nodes (w32tm /query /config shows correct peer)
  • Windows Time service running (Get-Service w32time | Select Status)
  • Stratum below 16 on all nodes (w32tm /query /status)
  • Clock skew within 5 minutes on all nodes (Kerberos requirement)

Troubleshooting

IssueRoot CauseRemediation
Script hard-fails on startupREPLACE placeholder value remainsEdit #region CONFIGURATION with the NTP server from variables.yml
Stratum 16 after resyncNTP server unreachable or DNS not resolvingVerify NTP server IP; confirm Task 06 (DNS) passed; check firewall rules
w32tm /resync exits non-zeroTime service not yet fully startedWait 10 seconds and re-run w32tm /resync /force manually
Orchestrated: ntp_servers not foundKey missing or wrong path in variables.ymlConfirm active_directory.ntp_servers: list exists in yml
Orchestrated: node unreachableWinRM not enabled or firewall blockingVerify WinRM configured (Task 01); check firewall allows port 5985/5986
Time keeps drifting backVM host overriding guest timeDisable Hyper-V Time Synchronization integration service if applicable

Task 06: Verify DNS↑ Phase 03: OS ConfigurationTask 08: Enable ICMP →

Version Control

VersionDateAuthorChanges
1.02026-01-31Azure Local Cloud Azure Local CloudnologyInitial document
2.02026-03-04Azure Local Cloud Azure Local CloudnologyFull rewrite to standards — complete frontmatter, bare-node 2-tab structure (Direct, Orchestrated), Standalone tab removed, YAML key corrected to active_directory.ntp_servers list, full embedded scripts with Assert-ConfigValues hard-fail, Get-YamlList and Get-ClusterNodes helpers