linux-root-rsync.sh
· 345 B · Bash
Raw
rsync -a \
--log-file=$logFile \
--exclude=/swap.img \
--exclude=/snap \
--exclude=/dev \
--exclude=/mnt \
--exclude=/proc \
--exclude=/sys \
--exclude=/tmp \
--exclude=/var/tmp \
--exclude=/var/log \
--exclude=/media \
--exclude=/usr/lib \
--exclude=/usr/src \
--exclude=/lost+found \
/ /other/location/to/sync/to
| 1 | rsync -a \ |
| 2 | --log-file=$logFile \ |
| 3 | --exclude=/swap.img \ |
| 4 | --exclude=/snap \ |
| 5 | --exclude=/dev \ |
| 6 | --exclude=/mnt \ |
| 7 | --exclude=/proc \ |
| 8 | --exclude=/sys \ |
| 9 | --exclude=/tmp \ |
| 10 | --exclude=/var/tmp \ |
| 11 | --exclude=/var/log \ |
| 12 | --exclude=/media \ |
| 13 | --exclude=/usr/lib \ |
| 14 | --exclude=/usr/src \ |
| 15 | --exclude=/lost+found \ |
| 16 | / /other/location/to/sync/to |
| 17 |