From 69940bc9ebefe8c1eb53699f9af022f209327561 Mon Sep 17 00:00:00 2001 From: root Date: Tue, 15 Sep 2026 11:42:10 +0000 Subject: [PATCH] fix: correct backup preflight commands - lvs pve/data and dmsetup field documentation Fix two errors in the PREFLIGHT section (measured on acerpve 2026-09-15): 1. lvs -o ... pve/data (not pve-data-tpool) - this is the PRIMARY check that yields percentages directly - Quote the acerpve example: data 29.95% 1.22% <816.21g 2. dmsetup status pve-data-tpool - document fields correctly: - = transaction ID (99), NOT data_percent - = metadata used/total blocks - = data used/total sectors - Show how to derive percentages if needed 3. Keep the error-state check (grep -q 'Error|Fail') - this is how the incident presented Everything else stays: 1777 tmpdir requirement with EACCES symptom, incidents as rationale, GPU-host fact, --output-format json rule, honest note that metadata/snapshot pressure is unproven. --- infrastructure-control.prose.md | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/infrastructure-control.prose.md b/infrastructure-control.prose.md index 26c9a0f..852fc86 100644 --- a/infrastructure-control.prose.md +++ b/infrastructure-control.prose.md @@ -381,16 +381,23 @@ Two incidents from 2026-09-13/14 demonstrate that backup operations can catastro Before starting ANY snapshot-mode vzdump on a host whose storage is an LVM thin pool, the following checks MUST pass: ```bash -# Check 1: Pool headroom -dmsetup status pve-data-tpool | awk '{print $4, $6}' # data_percent metadata_percent -lvs -o lv_name,data_percent,metadata_percent,lv_size pve-data-tpool - +# Check 1: Pool headroom (PRIMARY - yields percentages directly) +lvs -o lv_name,data_percent,metadata_percent,lv_size pve/data +# Example output (acerpve): +# LV Data% Meta% LSize +# data 29.95 1.22 <816.21g # Required thresholds (documented minimum): # data_percent < 90% (80% recommended for safety margin) # metadata_percent < 70% (metadata fills faster than data) -# Check 2: Verify pool is not in error state +# Check 2: Verify pool is not in error state (dmsetup shows the raw DM device) dmsetup status pve-data-tpool | grep -q "Error\|Fail" && exit 1 +# dmsetup output fields: / / +# $4 is transaction ID (99), NOT a percentage +# Example: 0 99 26676/2183168 4005020/13372736 +# Use $5 and $6 to calculate percentages if needed: +# data_percent = $6 / ($6 split by /) [second number in pair] +# metadata_percent = $5 / ($5 split by /) [second number in pair] ``` **Minimum thresholds**: If either `data_percent >= 90%` or `metadata_percent >= 70%`, the backup MUST NOT start. State explicitly that these are hard stops, not warnings.