Configure MCP maxUnavailable for Rollouts
Control how many nodes the MachineConfig Operator updates simultaneously. Set maxUnavailable for faster rollouts or safer one-at-a-time updates in production.
π‘ Quick Answer: Set
spec.maxUnavailableon your MachineConfigPool to control parallel updates. Default is1(sequential). Use1for production safety,2-3for faster dev/staging rollouts, or"33%"for percentage-based scaling.
The Problem
MCP updates are too slow (6 workers Γ 15 min each = 90 minutes for a simple chrony change) or too risky (updating multiple nodes simultaneously reduces cluster capacity).
The Solution
Check Current Setting
oc get mcp worker -o jsonpath='{.spec.maxUnavailable}'
# 1 β Default: one node at a timeChange maxUnavailable
# Update 2 nodes at a time
oc patch mcp worker --type merge -p '{"spec":{"maxUnavailable":2}}'
# Or use percentage
oc patch mcp worker --type merge -p '{"spec":{"maxUnavailable":"33%"}}'
# With 6 workers: 33% = 2 nodes simultaneouslyYAML Definition
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfigPool
metadata:
name: worker
spec:
maxUnavailable: 1 # Integer: exact count
# maxUnavailable: "25%" # Percentage: rounded up
machineConfigSelector:
matchLabels:
machineconfiguration.openshift.io/role: worker
nodeSelector:
matchLabels:
node-role.kubernetes.io/worker: ""Recommendations by Environment
| Environment | maxUnavailable | Reasoning |
|---|---|---|
| Production | 1 | Maximum safety β one failure doesnβt cascade |
| Staging | 2 or "33%" | Faster rollouts, acceptable risk |
| Dev/Lab | "50%" or 3 | Speed over safety |
| GPU workers | 1 | GPU workloads are expensive to reschedule |
Common Issues
Setting Too High Reduces Cluster Capacity
With maxUnavailable: 3 on a 6-worker cluster, half the cluster is unavailable during updates. Workloads may not have enough capacity.
Percentage Rounds Up
"25%" on 6 nodes = ceil(1.5) = 2 nodes. Always calculate the actual number.
Best Practices
- Use
1for production β predictable, safe, easy to troubleshoot - Increase temporarily for urgent patches, then reset to 1
- Create separate MCPs for different node types (GPU, infra, general) with different maxUnavailable
- Monitor during rollout β
oc get mcp -wshows real-time progress - Never set to total node count β leaves zero capacity during updates
Key Takeaways
maxUnavailablecontrols parallelism of MCP updates- Default
1is safest β nodes update one-by-one - Higher values speed up rollouts but reduce cluster capacity during updates
- Use separate MCPs for different risk profiles

Recommended
Kubernetes Recipes β The Complete Book100+ production-ready patterns with detailed explanations, best practices, and copy-paste YAML. Everything in one place.
Get the Book βLearn by Doing
CopyPasteLearn β Hands-on Cloud & DevOps CoursesMaster Kubernetes, Ansible, Terraform, and MLOps with interactive, copy-paste-run lessons. Start free.
Browse Courses βπ Deepen Your Skills β Hands-on Courses
Courses by CopyPasteLearn.com β Learn IT by Doing
