Configuration ManagerHow-to

Patching servers in order with Configuration Manager orchestration groups

Use orchestration groups to patch clustered or dependent servers one at a time or in batches, with approved pre and post scripts, sensible timeouts and a clean way to rerun a member.

Deploying the monthly updates to one big server collection is simple until two nodes of the same cluster restart at the same time. Orchestration groups in Configuration Manager fix that: they decide how many members of a group, or which one next, may install updates, and they can run a PowerShell script before and after each device. In this post I'll build an orchestration group for a two-node cluster, choose timeouts that fit your maintenance windows, and show how to monitor and rerun it.

How this guide is organized: How it works → Prerequisites and limits → Step-by-step → Verify → Tips and troubleshootingFlow diagram of the article's sections in reading order: 1. How it works. 2. Prerequisites and limits. 3. Step-by-step (5 steps: Write the pre and post scripts; Create the orchestration group; Size the timeouts; Approve the scripts; Deploy updates as usual). 4. Verify. 5. Tips and troubleshooting. Toolbox: WUAHandler.log, UpdatesDeployment.log, Monitoring › Deployments, UpdatesHandler.log.1How it works2Prerequisitesand limits3Step-by-step4Verify5Tips andtroubleshooti…1Write the pre andpost scripts2Create theorchestration gro…3Size the timeouts4Approve the scripts5Deploy updates asusualTOOLBOXWUAHandler.logUpdatesDeployment.logMonitoring › DeploymentsUpdatesHandler.logHow this guide is organized: How it works → Prerequisites and limits → Step-by-step → Verify → Tips and troubleshootingFlow diagram of the article's sections in reading order: 1. How it works. 2. Prerequisites and limits. 3. Step-by-step (5 steps: Write the pre and post scripts; Create the orchestration group; Size the timeouts; Approve the scripts; Deploy updates as usual). 4. Verify. 5. Tips and troubleshooting. Toolbox: WUAHandler.log, UpdatesDeployment.log, Monitoring › Deployments, UpdatesHandler.log.1How it works2Prerequisites and limits3Step-by-step1Write the pre and post scripts2Create the orchestration group3Size the timeouts4Approve the scripts5Deploy updates as usual4Verify5Tips and troubleshootingTOOLBOXWUAHandler.logUpdatesDeployment.logMonitoring › DeploymentsUpdatesHandler.log
At a glance: how this guide is organized · 5 steps · 4 key settings and tools

How it works#

What happens to each member of an orchestration groupStep 1: Wait for the member's turn. The rule decides: a percentage, a fixed number or an explicit maintenance sequence. Step 2: Run the pre-script. For a cluster, drain the node; scripts need approval and must return 0 for success. Step 3: Install the updates. From any deployment that reaches the member, within deadlines and maintenance windows. Step 4: Restart if required. Step 5: Run the post-script. Resume the node and check that it's Up before the next member starts. Step 6: Start the next member. The member timeout must cover all of this on your slowest node.1Wait for the member's turnThe rule decides: a percentage, afixed number or an explicitmaintenance sequence.2Run the pre-scriptFor a cluster, drain the node; scriptsneed approval and must return 0for success.3Install the updatesFrom any deployment that reachesthe member, within deadlines andmaintenance windows.4Restart if required5Run the post-scriptResume the node and check thatit's Up before the next memberstarts.6Start the next memberThe member timeout must cover allof this on your slowest node.What happens to each member of an orchestration groupStep 1: Wait for the member's turn. The rule decides: a percentage, a fixed number or an explicit maintenance sequence. Step 2: Run the pre-script. For a cluster, drain the node; scripts need approval and must return 0 for success. Step 3: Install the updates. From any deployment that reaches the member, within deadlines and maintenance windows. Step 4: Restart if required. Step 5: Run the post-script. Resume the node and check that it's Up before the next member starts. Step 6: Start the next member. The member timeout must cover all of this on your slowest node.1Wait for the member's turnThe rule decides: a percentage, a fixed number or anexplicit maintenance sequence.2Run the pre-scriptFor a cluster, drain the node; scripts need approval andmust return 0 for success.3Install the updatesFrom any deployment that reaches the member, withindeadlines and maintenance windows.4Restart if required5Run the post-scriptResume the node and check that it's Up before the nextmember starts.6Start the next memberThe member timeout must cover all of this on yourslowest node.
Figure 1 · Process What happens to each member of an orchestration group. Every member runs this sequence inside its member timeout. With a maintenance sequence, a failing post-script stops the run before the next node goes down.

An orchestration group is a console object that lists devices and a rule. The rule applies to every software update deployment that reaches a member, through any collection, so you keep deploying updates to your normal server collections. Deadlines, maintenance windows and deployment schedules still apply. Within those, the group lets members update in one of three ways:

  • Allow a percentage of the machines to be updated at the same time: with 50 members and 10%, five devices update at once, and the number grows with the group.
  • Allow a number of the machines to be updated at the same time: a fixed count, whatever the group size.
  • Specify the maintenance sequence: an explicit order, one device at a time.

For each member, the flow is: pre-script, update installation, a restart if required, then the post-script. Orchestration groups are the evolution of the older Server Groups feature. Enabling orchestration groups turns server groups off, and sites that had server groups enabled had them moved to orchestration groups automatically when they installed version 2002 or later. Since version 2111 the feature is no longer pre-release.

Prerequisites and limits#

  • Enable Orchestration Groups under Administration › Updates and Servicing › Features.
  • Use a Full Administrator account: role-based administration isn't available for orchestration groups, and approving their scripts needs Full Administrator or Operations Administrator.
  • Keep members on the latest client version and assigned to the same site. A device can belong to only one orchestration group, and a group can have up to 1,000 members.
  • Orchestration groups don't work while the hierarchy is in interoperability mode.
  • Two bypasses to remember: updates a user starts from Software Center skip orchestration, and so do updates in the Definition classification.

Step-by-step#

1. Write the pre and post scripts#

Scripts can't take parameters, are limited to 50,000 bytes, and must return 0 for success; anything else is a failure. Use $env:COMPUTERNAME instead of parameters. A pre-script that drains a failover cluster node:

PowerShell
try {
    Import-Module FailoverClusters -ErrorAction Stop
    Suspend-ClusterNode -Name $env:COMPUTERNAME -Drain -Wait -ErrorAction Stop | Out-Null
    exit 0
} catch {
    exit 1
}

And a post-script that brings the node back and checks it, so a failure stops the sequence before the next node goes down:

PowerShell
try {
    Import-Module FailoverClusters -ErrorAction Stop
    Resume-ClusterNode -Name $env:COMPUTERNAME -Failback Immediate -ErrorAction Stop | Out-Null
    if ((Get-ClusterNode -Name $env:COMPUTERNAME).State -ne 'Up') { exit 1 }
    exit 0
} catch {
    exit 1
}

2. Create the orchestration group#

  1. Go to Assets and Compliance › Orchestration Group and select Create Orchestration Group.
  2. On General, enter a name and set the two timeouts. Orchestration Group timeout (in minutes) limits how long all members together may take; Orchestration Group member timeout (in minutes) limits a single device.
  3. Add the members (both cluster nodes, from the same site).
  4. Choose the rule. For a cluster, use Specify the maintenance sequence and order the nodes.
  5. On the Script Picker page, add the pre-script and post-script (paste them, open a .ps1 file, or browse to an approved script from the Scripts list) and set each Script timeout (in seconds).

3. Size the timeouts#

The member timeout must cover the pre-script, update installation, the restart and the post-script on your slowest node. Measure a normal patch night and add a margin. In sequence mode the group timeout needs to cover every member in turn, so it should be at least the member timeout multiplied by the number of members, and the whole run must fit inside the maintenance window. Otherwise the last node simply waits for the next window.

4. Approve the scripts#

Since version 2111, pre-scripts and post-scripts don't run until someone approves them, and editing an approved script puts it back to Waiting for approval. The Scripts tab of the orchestration group shows each script's approval status. If your hierarchy requires a second approver for scripts, plan for that before patch night (see CMPivot and Run Scripts).

5. Deploy updates as usual#

Nothing changes in the deployment itself: your automatic deployment rule or software update group targets the server collection with a deadline, and the maintenance windows on the server collections decide when installation can start. The orchestration group only controls who goes next. For a ring design, see automatic deployment rules for Patch Tuesday.

Verify#

  1. Group members: in the Orchestration Group node, open the group's members and check each device's orchestration state and when it finished. The nodes should finish one after the other, never together.
  2. Deployment status: under Monitoring › Deployments, every member reports Compliant.
  3. On each server: no deployed updates should still be pending, and the cluster should be healthy:
PowerShell
Get-CimInstance -Namespace root\ccm\ClientSDK -ClassName CCM_SoftwareUpdate |
    Select-Object ArticleID, Name, EvaluationState
Get-ClusterNode | Select-Object Name, State

Good looks like this: the first command returns nothing, and every node is Up.

Tips and troubleshooting#

  • A member doesn't start: check the maintenance window first (deployments waiting for a maintenance window), then whether an earlier member is still running or has failed.
  • Scripts never run: they're unapproved, or they were edited after approval.
  • A member failed or completed and you need to rerun it: right-click it and select Reset Orchestration Group Member, which clears states such as Complete or Failed.
  • Updates installed out of order: someone selected Install in Software Center, which bypasses orchestration. For these servers, set the deployment's user notifications to hide in Software Center, or brief the server owners.
  • Updates install but report failures: troubleshoot the client side as usual with WUAHandler.log, UpdatesDeployment.log and UpdatesHandler.log (see updates not installing), and look up codes in the software update error codes quick reference.

References#

Written and checked against current Microsoft Learn documentation. Test changes with a pilot group before rolling them out to everyone, and if an admin center path has moved since, search for the setting name instead.

Spotted a mistake, or did this fix work differently for you? Email me or message me on LinkedIn — corrections are credited in the article.

Written by

Omer Eltayeb

Intune Subject Matter Expert in Cairo, Egypt, former Microsoft Cloud Solutions Architect, Microsoft Certified Trainer and Microsoft Innovative Educator Expert (2024–26) and Microsoft Elevate Educator Expert (2026–27). I share practical, step-by-step guides, study plans, scripts and toolkits for Microsoft Intune, Configuration Manager, Microsoft Entra ID, Microsoft Defender, Exchange and Microsoft 365 with the community.

Microsoft Certified Trainer (MCT) 2026Microsoft Innovative Educator Expert 2025–2026Microsoft Elevate Educator Expert 2026–2027ISC2 Certified Information Systems Security Professional (CISSP)Microsoft 365 Certified: Enterprise Administrator Expert (MS-102)