/secure-server-skills:backup-strategyfrom secure-server-skills
Designs and verifies Linux backup and recovery strategies for files and databases. Covers encryption, retention, S3 transfer, and restore testing with Bash, MySQL, GPG, and AWS CLI.
Ships in secure-server-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Define recoverable data and recovery objectives before scheduling jobs or deleting generations. A selected-directory archive is not a full machine image; a successful upload or gzip check is not an application restore test.
Read references/backup-locations.md for storage decisions, failure handling, schedules and safe restoration.
The helpers preview by default, require explicit inputs, create private output and checksum files, serialize jobs in a backup directory, and publish only verified results. Optional GPG encryption uses an already-provisioned public key; failed encryption retains the verified compressed source as a protected pending file.
Preview file backups:
bash scripts/backup-full.sh --path /etc --path /var/www --backup-dir /backup/files --dry-run
After the data scope and storage are authorized, use --apply. Add --gpg-recipient for the chosen encryption key. Missing/invalid inputs fail instead of silently excluding required data. GNU tar captures selected-directory metadata; review restore permissions, ACLs and extended attributes on the target.
Preview MySQL backups:
bash scripts/backup-mysql.sh --defaults-file /secure/mysql-backup.cnf --database application --backup-dir /backup/mysql --dry-run
The option file must be private and owned by the executing user. No password is passed in argv. Repeat --database for every application database. The helper refuses non-InnoDB tables; system databases and other engines need a separately reviewed snapshot/locking procedure. --apply --maintenance-confirmed attests the no-concurrent-DDL window. Verify routine/event privileges and successful restoration for the installed database version.
The S3 helper takes explicit artifact paths, verifies their adjacent checksums, uploads to the approved prefix, downloads them to compare bytes, then uploads checksums. It retains local copies and changes no bucket lifecycle or credentials.
bash scripts/backup-to-s3.sh --s3-uri s3://approved-backups/server-a --file /backup/files/FILE_ARCHIVE --file /backup/mysql/DATABASE_ARCHIVE --dry-run
Substitute the actual generated artifact paths before use. --apply performs the upload/readback and incurs transfer/storage costs. Specify --kms-key-id only for an approved accessible key; default uploads use S3 AES256 encryption. Uploaded ciphertext still needs independent private-key recovery testing.
Local retention is disabled unless --prune is explicitly selected. Preview it with --dry-run --prune --retention-days 30; --apply --prune prunes only after a new successful archive is published. Only regular matching artifacts directly inside the dedicated backup directory, older than the selected age and having valid checksums, qualify. Prior legacy/unverified archives are preserved for manual review. Scope scheduled cleanup to the already-authorized retention policy, and retain enough independent verified generations to meet recovery needs.
The helpers share scripts/backup-common.sh; keep it beside them when copying or installing scripts.
/etc, /root, users or old credentials directly over a running system as a routine test.Report archive validation, remote byte verification, and application recovery as separate outcomes. Avoid deleting useful generations after failed dumps, encryption, transfer, or restore checks.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
backup, recovery, disaster-recovery, linux-backup, database-backup
Other plugins' skills for the same job
npx claudepluginhub mikr13/secure-server-setup-skills --plugin secure-server-skills5 skills in this plugin
/auto-updatesAudit or configure unattended upgrades on Ubuntu/Debian. Use for security-update scheduling, allowed origins and reboot policy./fail2ban-setupAudit or configure Fail2ban SSH jails on Ubuntu/Debian. Use for log backends, filter behavior and ban enforcement./firewall-configurationAudit or configure UFW on Ubuntu/Debian. Use for source-restricted services and IPv4/IPv6 network exposure checks./ssh-hardeningAudit or harden OpenSSH on Ubuntu/Debian with verified key access. Use when changing authentication or administrative SSH access.