Skip to main content

Backup & Recovery

Backup procedures and restore operations.


Architecture

Primary: odin (Mac Mini M4)

├── Local Backup: T9 SSD
│ /Volumes/T9/restic-homelab

└── Offsite Backup: Backblaze B2
b2:ravenhelm:ravenhelm-homelab

Schedule

BackupScheduleRetention
Local (T9)2:30 AM daily7 daily, 4 weekly, 12 monthly
B2 Offsite3:30 AM weeklySame as local

Quick Commands

# Run full backup
source ~/.config/restic/homelab.env
restic backup ~/ravenhelm

# List snapshots
restic snapshots

# Check repository
restic check

# Restore file
restic restore latest --include <path> --target /tmp/restore

Backup Configuration

Local (.config/restic/homelab.env)

export RESTIC_REPOSITORY="/Volumes/T9/restic-homelab"
export RESTIC_PASSWORD_COMMAND='op read "op://ravenmask/restic-homelab/password"'

B2 Offsite (.config/restic/b2.env)

export RESTIC_REPOSITORY="b2:ravenhelm:ravenhelm-homelab"
export B2_ACCOUNT_ID=$(op read "op://ravenmask/backblaze ravenhelm api key/keyID")
export B2_ACCOUNT_KEY=$(op read "op://ravenmask/backblaze ravenhelm api key/credential")
export RESTIC_PASSWORD_COMMAND='op read "op://ravenmask/restic-homelab/password"'

What's Backed Up

PathPriorityNotes
~/ravenhelm/data/CriticalAll service data
~/ravenhelm/secrets/CriticalCredentials
~/ravenhelm/services/HighCompose files
~/ravenhelm/scripts/MediumAutomation

Restore Procedures

Single File

source ~/.config/restic/homelab.env
restic restore latest --include ~/ravenhelm/data/postgres --target /tmp/restore

Full Restore

See Disaster Recovery.


Monitoring

Check backup status:

# Last backup time
restic snapshots --latest 1

# Repository health
restic check

Alert on backup failures via n8n workflow.