Article Title: Linux uses tar to back up the system. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
Tar-zcvpf/home/full-backup.tar.gz/-- exclude =/mnt/* -- exclude =/proc/* -- exclude =/sys /*
This command uploads all contents under the root directory to the backup document of full-bakup.tar.gz.
-Z indicates compressed gzip format
-C (create a backup document
-V shows the compression process
-P: Retain file permissions
-- Directory 'specifies a folder that is not backed up
Incremental Backup
1. Create a full backup: tar-czvf-g zeng aa.tar.gz/var
After the data in/var changes
2. Perform Incremental backup again: tar-czvf-g zeng aa.tar.gz. 1/var
Differential backup
1. find/var-mtime-1-print> filelist
List of files to be backed up-1 indicates the time of the day
2. tar-czv-T filelist-f/backup.tar.gz
Backup Based on the file list.-T option can specify a list of files to be backed up