Bring script headers onto the template and close safeguard gaps
Headers claimed protections the code never had, and several destructive paths had no guard against a collapsed config value.
This commit is contained in:
@@ -19,6 +19,24 @@
|
||||
# to HOST*_DAILY_SYNC_SHARES. Both aliased by detect_hosts().
|
||||
#
|
||||
# ==============================================================================================
|
||||
# OPERATIONAL MODEL
|
||||
# ==============================================================================================
|
||||
#
|
||||
# 1. Pre-flight — connectivity to the remote, remote array mounted, version parity
|
||||
# 2. Resolve the share list (BACKUP_VERIFY_SHARES, else DAILY_SYNC_SHARES)
|
||||
# 3. Per share:
|
||||
# a. Randomly sample BACKUP_VERIFY_SAMPLE files above BACKUP_VERIFY_MIN_SIZE
|
||||
# b. Compute each file's MD5 locally
|
||||
# c. Compute the same file's MD5 on the remote over SSH
|
||||
# d. Classify: MATCH | MISMATCH | MISSING
|
||||
# 4. Report per-share and overall counts; notify on any MISMATCH and on
|
||||
# significant MISSING counts
|
||||
#
|
||||
# Sampling rather than full verification is deliberate — a complete checksum of every
|
||||
# mirrored file would take longer than the interval between runs. Random sampling over
|
||||
# a weekly cadence surfaces systematic corruption without ever reading the whole library.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# DESIGN PRINCIPLES
|
||||
# ==============================================================================================
|
||||
#
|
||||
@@ -56,9 +74,6 @@
|
||||
# SSH Timeout
|
||||
# SSH_TIMEOUT caps all SSH calls. One hung connection does not block the run.
|
||||
#
|
||||
# Notification Validated
|
||||
# platform_require_cmd confirms the notify script is present before use.
|
||||
#
|
||||
# ==============================================================================================
|
||||
# CONFIGURATION
|
||||
# ==============================================================================================
|
||||
|
||||
Reference in New Issue
Block a user