Proxmox VEXI · ClusteringCluster recovery
Cold-starting a cluster from a full shutdown
What you'll learn
- Sequence a planned full-cluster shutdown so that the restart is uneventful
- Explain why a cluster that is half powered on is the worst state to make decisions in
- Order storage, quorum, HA and guest startup correctly on the way back up
- Verify a cold-started cluster against an inventory rather than against a dashboard
Prerequisites
Verified against Proxmox VE 9.2.4 · Proxmox Backup Server 4.2.5 · Ceph Squid / Tentacle · Debian 13 (Trixie) · Linux kernel 7.0 (PVE 9.2 default) · 2026-08-12
Most cluster procedures assume a cluster that is running. Cold start is the
one that assumes nothing: every node dark, /etc/pve unreachable because
there is no pmxcfs to serve it, no quorum because there is nobody to vote,
and a room full of hardware that is about to come back in an order nobody
chose.
It happens for two reasons, and they need different preparation:
- Planned. A UPS replacement, a generator test, an electrical inspection, a data-centre move, a chilled-water outage announced two weeks ahead.
- Unplanned. The power failed and the UPS ran out.
The planned case is the one to get right, because a cluster that has been shut down cleanly comes back cleanly. The unplanned case is survivable largely to the extent that you had already rehearsed the planned one.
The fact that shapes everything
A cluster is not quorate when all nodes are offline. That is a tautology, but its consequences are not obvious until you are standing in front of it:
- On boot,
pve-clusterstarts and pmxcfs mounts/etc/pveread-only, because a single node in a three-node cluster has one vote out of three. pve-guests, the unit responsible for autostarting guests, waits for quorum before it starts anything. Guests withonboot: 1do not start on the first node, or the second — they start when the majority is present.- The HA stack behaves the same way. The local resource manager cannot reset its watchdog without quorum, and the cluster resource manager makes no placement decisions until the cluster is quorate.
So the first node up looks broken. It is not broken. It is waiting, exactly as designed, and the correct response is to bring up the next node.
Planned shutdown: the order that makes the restart boring
Shutting down is where the work happens. Everything you do here is something you do not have to reason about at 04:00 on the way back up.
set -euo pipefail
# What is HA currently managing? Capture it - this is your restart checklist.
ha-manager status > /root/cold-start-ha-state.txt
ha-manager config >> /root/cold-start-ha-state.txt
cat /root/cold-start-ha-state.txt
# Capture the full guest inventory and its run state, on every node.
# This is what you will verify against tomorrow. Take it now, while it is true.
for node in $(pvecm nodes | awk 'NR>3 {print $3}'); do
echo "== $node"
ssh "$node" 'qm list; pct list'
done > /root/cold-start-inventory.txt
# Disable replication jobs so none fire mid-shutdown.
pvesr listset -euo pipefail
# The startup option controls both directions. order is the sequence,
# up is the delay after starting before the next guest, down is how long
# to wait for this guest to shut down before moving on.
# Lower order numbers start FIRST and shut down LAST.
#
# qm set 101 --startup order=1,up=30,down=120 # domain controller / DNS
# qm set 110 --startup order=2,up=15 # database
# qm set 120 --startup order=3 # application servers
#
# If ordering is unset across the estate, drive the shutdown manually,
# most-dependent first:
VMID=120
qm shutdown "$VMID" --timeout 300
# A guest that will not shut down cleanly within its timeout is a decision,
# not an automatic stop. Find out why before you reach for qm stop.
qm status "$VMID"set -euo pipefail
# Only on a cluster running Ceph. Confirm health BEFORE you set flags -
# shutting down a cluster that is already degraded is a different procedure.
ceph -s
# Stop Ceph reacting to OSDs that are about to disappear on purpose.
ceph osd set noout
ceph osd set norebalance
ceph osd set norecover
# Confirm the flags are set before proceeding.
ceph osd statset -euo pipefail
# Shut down nodes one at a time. On each, confirm no guests are running
# before pulling it out from under anything.
qm list
pct list
# Then, on that node:
shutdown -h now
# Keep the last node with quorum until the end. On a three-node cluster you
# will lose quorum when the second node goes down; that is expected and
# harmless once every guest is already stopped.Bringing it back up
The ordering is dictated by dependencies, not by convenience. Each layer needs the one below it.
| Step | What | Wait for | Why this order |
|---|---|---|---|
| 1 | Network: switches, routers, the corosync fabric | Link up, spanning tree converged | Nodes that boot into a dead network will not see each other and will look like a partition |
| 2 | External storage: SAN, NFS server, iSCSI targets | Targets reachable and exporting | Guests on shared storage cannot start without it, and a node can mount storage before it has quorum |
| 3 | PVE nodes, ideally all together | Quorum, confirmed with pvecm status | Nothing else in this table can proceed until the cluster is quorate |
| 4 | Ceph, if present | HEALTH_OK or a documented, understood HEALTH_WARN | Monitors need their own quorum before OSDs can serve I/O |
| 5 | Clear the Ceph maintenance flags | Rebalancing settles | Leaving noout set indefinitely means a genuinely failed OSD is never recovered |
| 6 | Verify storage is active in PVE | pvesm status shows every storage active | A guest that starts against inactive storage fails in a confusing way |
| 7 | Guests, in dependency order | Each tier healthy before the next | This is what startup order automates, if you set it |
| 8 | HA re-enabled, replication resumed | ha-manager status normal | HA acting during the restart will fight you |
set -euo pipefail
# Poll until quorate. If it never becomes quorate, the answer is on the
# nodes that have not appeared, not on this one.
pvecm status
# Which nodes are present at the corosync layer right now?
corosync-cfgtool -n
# Count what you have against what you need. Expected votes comes from
# corosync.conf; total votes is what is actually here.
pvecm status | grep -E 'Quorate|Total votes|Expected votes|Activity blocked'set -euo pipefail
# Only once every OSD you expect is up and in.
ceph osd stat
ceph -s
ceph osd unset norecover
ceph osd unset norebalance
ceph osd unset noout
# Watch recovery settle rather than assuming it does.
ceph -sVerifying against an inventory, not a dashboard
The dashboard shows what is running. It cannot show what is missing, because a guest that never started does not draw attention to itself. The inventory you captured in phase 1 is what closes that gap.
set -euo pipefail
# Regenerate the same view you captured before the shutdown.
for node in $(pvecm nodes | awk 'NR>3 {print $3}'); do
echo "== $node"
ssh "$node" 'qm list; pct list'
done > /root/cold-start-inventory-after.txt
diff /root/cold-start-inventory.txt /root/cold-start-inventory-after.txt || true
# Guests configured to autostart that are nevertheless stopped.
for vmid in $(qm list | awk 'NR>1 {print $1}'); do
onboot=$(qm config "$vmid" | awk '/^onboot:/ {print $2}')
state=$(qm status "$vmid" | awk '{print $2}')
if [ "$onboot" = "1" ] && [ "$state" != "running" ]; then
printf '%-6s onboot-but-stopped\n' "$vmid"
fi
done
# HA should be back to the state you captured, not to a state full of errors.
ha-manager statusA break/fix exercise
Half the cluster boots after a power failure and nothing starts
Symptoms
- Two of five nodes are up and reachable; three are not responding
- The web interface loads on both live nodes and shows all five nodes, three greyed out
- No guests have started; every start attempt returns a 500 error
- pvecm status reports Quorate: No, Total votes: 2, Expected votes: 5, Activity blocked
Available evidence
- Utility power was restored 20 minutes ago after a four-hour outage
- iDRAC on two of the three missing nodes is reachable and reports the nodes are powered off
- iDRAC on the third missing node does not respond at all
- The two live nodes are on rack PDU A; the three missing nodes are on rack PDU B
- PDU B shows no output on any outlet
Show diagnosis & remediation
Root cause
This is not a cluster fault. Two votes out of five is not a majority, so pmxcfs is read-only and pve-guests is correctly waiting for quorum before starting anything. The missing votes are missing because PDU B has not restored output - an electrical fault, not a corosync one.
Safe remediation
Do not force quorum. Escalate the PDU fault to facilities and get power restored to the three remaining nodes; they will boot, corosync will form a five-node membership, quorum will be reached and pve-guests will start the onboot guests without further intervention. While waiting, use out-of-band management to confirm the state of each missing node so you know what to expect when power returns, and check whether the third node - whose iDRAC is also dark - has a separate fault that will need attention once its PDU is live.
Verification
pvecm status shows Quorate: Yes with Total votes: 5. A write probe into /etc/pve succeeds on every node. pvesm status shows every storage active. The guest inventory captured before the outage matches the running set, with a named reason for every difference. ha-manager status shows no services in an error state.
Prevention
Split cluster nodes across independent PDUs and phases so that no single power path can remove a majority of votes at once - with five nodes, no PDU should carry more than two. Record the node-to-PDU mapping in the cluster inventory so that a missing-votes pattern can be matched to a power path in seconds rather than guessed at. Rehearse a planned full shutdown and cold start annually, and set BIOS power restore policy consistently across the estate so the boot order after a power event is a known quantity rather than a surprise.
Common mistakes
- Forcing quorum because the nodes are slow to boot. Boot takes minutes; a modern server with a lot of RAM can spend five of them in POST alone. Waiting is free.
- Leaving
nooutset after the restart. It is a maintenance flag, not a configuration setting. - Never having captured the inventory. Without a before list, “everything is back” is an assertion, not a finding.
- Assuming HA will sort it out. HA cannot act until the cluster is quorate, which is the exact condition you are trying to reach.
- Powering on the whole rack at once after a long outage. Inrush current on a rack full of servers spinning up disks simultaneously can trip the breaker you just got back. Stagger it.
- Treating cold start as a procedure you can write during the incident. It is the one procedure that has to exist on paper, off-cluster, because the wiki that documents it may be running on the cluster.
Key takeaways
- All nodes down means no quorum by definition; the first node up will look broken and is not.
- The dangerous state is a partially powered cluster, and the dangerous action is forcing quorum inside it.
- Order on the way down: HA frozen, guests stopped by dependency, Ceph flagged, nodes off. Order on the way up: network, storage, quorum, Ceph, storage verified, guests, HA.
startup orderon the guests is the durable record of your dependency graph. Set it before you need it.- Verify against the inventory you captured, not against the dashboard.
Knowledge check
Knowledge check · 5 questions
Q1. After a data-centre power failure, the first node of a five-node cluster finishes booting. Its web interface loads but /etc/pve is read-only and none of its onboot guests have started. What is happening?
Q2. Which of these belong in a planned full-cluster shutdown, before any node is powered off? Select all that apply.
Q3. On a cluster with external NFS or iSCSI storage, the PVE nodes should be powered on before the storage systems, so that they are ready to mount as soon as storage appears.
Q4. Twelve hours after a cold start, one OSD has still not returned and the cluster is running with noout, norebalance and norecover still set. What should be done?
Q5. What does the startup order option on a guest actually record, and why does it matter for a cold start?
Passing score: 75%. Answers are checked in this browser.