mirror of
https://github.com/acedanger/shell.git
synced 2025-12-06 06:40:13 -08:00
feat: Revamp Plex backup system to streamline archive structure and enhance validation processes
This commit is contained in:
32
README.md
32
README.md
@@ -129,10 +129,10 @@ Specialized backup system for Plex Media Server with database-aware features:
|
||||
./validate-plex-backups.sh
|
||||
|
||||
# Test restore without making changes (dry run)
|
||||
./restore-plex.sh 20250125 --dry-run
|
||||
./restore-plex.sh plex-backup-20250125_143022.tar.gz --dry-run
|
||||
|
||||
# Restore from specific backup
|
||||
./restore-plex.sh 20250125
|
||||
# Restore from specific backup archive
|
||||
./restore-plex.sh plex-backup-20250125_143022.tar.gz
|
||||
```
|
||||
|
||||
## Automation and Scheduling
|
||||
@@ -183,10 +183,32 @@ The enhanced media backup script includes configurable parameters at the top of
|
||||
The Plex backup script configuration parameters:
|
||||
|
||||
- `MAX_BACKUP_AGE_DAYS=30`: Remove backups older than 30 days
|
||||
- `MAX_BACKUPS_TO_KEEP=10`: Keep maximum of 10 backup sets
|
||||
- `BACKUP_ROOT`: Location for backup storage
|
||||
- `MAX_BACKUPS_TO_KEEP=10`: Keep maximum of 10 backup archives
|
||||
- `BACKUP_ROOT`: Location for compressed backup archives
|
||||
- `LOG_ROOT`: Location for backup logs
|
||||
|
||||
### Final Backup Directory Structure
|
||||
|
||||
The enhanced Plex backup system creates a streamlined archive-only structure:
|
||||
|
||||
```bash
|
||||
/mnt/share/media/backups/plex/
|
||||
├── plex-backup-20250125_143022.tar.gz # Latest backup
|
||||
├── plex-backup-20250124_143011.tar.gz # Previous backup
|
||||
├── plex-backup-20250123_143008.tar.gz # Older backup
|
||||
└── logs/
|
||||
├── backup_log_20250125_143022.md
|
||||
├── plex-backup-performance.json
|
||||
└── plex-backup.json
|
||||
```
|
||||
|
||||
**Key Benefits:**
|
||||
|
||||
- **Direct Archive Storage**: No intermediate directories required
|
||||
- **Efficient Space Usage**: Only compressed files stored permanently
|
||||
- **Easy Management**: Timestamp-based naming for clear identification
|
||||
- **Automatic Cleanup**: Legacy dated directories removed automatically
|
||||
|
||||
### Recommended Backup Strategy
|
||||
|
||||
Both systems implement a robust backup strategy following industry best practices:
|
||||
|
||||
Reference in New Issue
Block a user