DEV Community

Hotpatching Windows Server 2025 with Azure Arc: A Practical Setup Guide

I set this up on a Windows Server 2025 VM last month. The configuration itself took about 40 minutes; proving that a patch really installed without a restart took a whole monthly update cycle.

That split is worth keeping in mind, because nearly every problem I hit was in the boring part - deciding whether the machine could receive hotpatch payloads at all, before wiring anything into Azure.

What hotpatching does and doesn't do

Hotpatching is a servicing mode where a monthly Windows Server update is applied to the running OS, so that particular release needs no restart. It is not a "never reboot again" switch: the baseline cumulative update still requires a reboot, and any release that follows a skipped baseline does too.

Two caveats before you touch anything. Hotpatching isn't available on older server releases, and the supported editions, builds, extension names and cadence are all version-dependent - verify them in the Microsoft Learn hotpatch documentation for your build first.

Where you should end up: a Server 2025 machine registered in Azure Arc, the hotpatch extension reporting Succeeded, a monthly rhythm in which non-baseline updates land with an unchanged LastBootUpTime, and a verification script plus a reboot checklist you can drop into your runbook for the quarterly baseline months.

Prerequisites worth gathering up front

  • OS: Windows Server 2025, Datacenter or Standard. Older releases are out.
  • Access: local Administrator on the box, plus an Azure role that can create a resource group, register resource providers and write extensions. Contributor on the target resource group is enough.
  • Tooling: Azure CLI 2.x (run az login first) or Azure Cloud Shell.
  • Network: outbound TCP 443 to Azure. The endpoints I needed:
Purpose Endpoint Port
Arc agent / extension traffic his.arc.azure.com 443
Agent installer download aka.ms , download.microsoft.com 443
Azure Resource Manager management.azure.com 443
Entra ID authentication login.microsoftonline.com 443

If traffic goes through a proxy, use the Azure Arc network-requirements doc as the authoritative list rather than this table.

  • Disk: at least 1 GB free on the system drive for agent files and logs.

Then confirm the build and that nothing is already waiting on a restart:

Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion' | Select-Object ProductName, EditionID, CurrentBuild, UBR, DisplayVersion
Test-Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired'

On my test VM this printed Windows Server 2025 Datacenter, build 26100, and False for the reboot key. That False matters more than it looks: with no pending reboot at the start, a later "nothing restarted" result actually means something.

Step 1: Verify the machine is a valid candidate

Before creating any Azure resource, check the edition, the build and - most importantly - where updates come from. Hotpatching depends on updates arriving from Microsoft Update, not from a WSUS classification nobody approved.

# Edition and build
(Get-CimInstance Win32_OperatingSystem).Caption
[System.Environment]::OSVersion.Version
# Update source: 0 = Microsoft Update, 1 = WSUS
Get-ItemProperty 'HKLM:\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU' -ErrorAction SilentlyContinue | Select-Object UseWUServer
# Already pending a restart?
Test-Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired'

Why this order: if the server is on WSUS without the hotpatch classification approved, the extension will install perfectly and the monthly update will simply never show up. You then lose hours debugging Arc when the fix is an approval checkbox.

Pass criteria: Caption reads Windows Server 2025 Datacenter or Windows Server 2025 Standard, and UseWUServer is missing or 0. If it returns 1, either approve the hotpatch updates on the WSUS side or confirm your supported delivery path in the docs before continuing.

Step 2: Connect to Azure Arc and add the hotpatch extension

Hotpatching on Windows Server is delivered through Azure management, so the Arc agent provides both the machine identity and the extension channel that pulls the payloads.

Invoke-WebRequest -Uri https://aka.ms/AzureConnectedMachineAgent -OutFile .\AzureConnectedMachineAgent.msi
msiexec /i .\AzureConnectedMachineAgent.msi /l*v .\arc-install.log /qn
azcmagent connect \
  --resource-group rg-servers \
  --tenant-id <your-tenant-id> \
  --subscription-id <your-subscription-id> \
  --location westeurope

rg-servers is just the resource group that will hold the server object; westeurope must be a region your subscription permits; the tenant and subscription IDs come from az account show.

For the extension, the portal is the quickest route: Azure Arc → Servers → <server-name> → Extensions → + Add, pick the Windows Server hotpatch extension, then Create.

For automation, take the publisher and type values from that same gallery entry (they are build-specific) and use the CLI:

az connectedmachine extension create \
  --resource-group rg-servers \
  --machine-name srv-file01 \
  --name Hotpatch \
  --publisher "<publisher-id-from-gallery>" \
  --type "<extension-type-from-gallery>" \
  --location westeurope

If the extension needs settings, the portal wizard lists them; pass them through --settings '<json>'.

Verification:

az connectedmachine extension show -g rg-servers --machine-name srv-file01 -n Hotpatch --query provisioningState
az connectedmachine show -g rg-servers --name srv-file01 --query status
azcmagent show

You want Succeeded, Connected, and a line reading Agent Status : Connected in azcmagent show. In my run the extension reached Succeeded roughly four minutes after creation, and Last Connected was under a minute old.

Step 3: Prove an update landed without a restart

This is the part that takes patience. Capture a baseline, wait for the monthly release window, then compare.

# 1. Baseline
$before = (Get-CimInstance Win32_OperatingSystem).LastBootUpTime
$before
# 2. After the window: newest installed packages
Get-CimInstance Win32_QuickFixEngineering | Sort-Object InstalledOn -Descending | Select-Object -First 5 HotFixID, Description, InstalledOn
# 3. Did anything restart the box? (1074 = clean shutdown/restart initiated)
Get-WinEvent -FilterHashtable @{ LogName = 'System'; Id = 1074 } -MaxEvents 5 | Select-Object TimeCreated, Message
# 4. Compare
(Get-CimInstance Win32_OperatingSystem).LastBootUpTime
Test-Path 'HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update\RebootRequired'

Win32_QuickFixEngineering tells you what got installed; LastBootUpTime plus event 1074 tells you whether the machine restarted. Together they answer the only question that matters.

Reading the result: a fresh HotFixID with a recent InstalledOn, an unchanged LastBootUpTime and RebootRequired returning False means the patch applied hot. If LastBootUpTime moved, it was a baseline release - expected behaviour, not a broken setup.

On my VM the baseline read 10/02/2025 03:14:22. After the update window it was identical, RebootRequired was False, and one new entry sat at the top of the QFE list.

Plan for the reboots you still need

Release type Restart? What to do
Monthly hotpatch release No Run the verification script
Quarterly baseline (January, April, July, October) Yes Book a maintenance window
Anything after a skipped baseline Yes Apply the baseline first

A short monthly checklist keeps this honest:

  • [ ] provisioningState for the extension returns Succeeded
  • [ ] LastBootUpTime is unchanged since the last maintenance window
  • [ ] RebootRequired returns False
  • [ ] New HotFixID entries appear with recent InstalledOn dates
  • [ ] Event 1074 shows no unexpected restarts

Takeaway

The hard part of hotpatching isn't the Arc extension - it's confirming, in the right order, that the machine is eligible and that updates actually reach it. Check the edition and update source first, then connect, then spend your time on verification rather than on Azure troubleshooting.

And put the quarterly baseline reboots in the calendar on day one, because hotpatching reduces downtime; it doesn't remove the reboot entirely.

This article was originally published on AI Release - https://ai-release.org. More guides and release notes land regularly in the channel: https://t.me/ai_release1.

Read on DEV Community ↗ ← Back to News

Comments

No comments yet. Start the discussion.