Ubuntu 备份系统

2024-09-17 14:50:42
``` tar cvpzf /backup/system_backup_$(date +%Y%m%d).tar.gz --exclude=/backup --exclude=/dev --exclude=/proc --exclude=/sys --exclude=/tmp --exclude=/run --exclude=/mnt --exclude=/media --exclude=/swap.img --exclude=/lost+found / # rsync aAXv exclude={"/dev/*","/proc/*","/sys/*","/tmp/*","/run/*","/mnt/*","/media/*","/lost+found"} / /backup/system_backup/$(date +%Y%m%d) delete ```