This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
backup_script [2025/06/11 15:32] – [Goals] -Change "we" to "you" hogwild | backup_script [2025/06/20 19:06] (current) – [Goals] thilo | ||
---|---|---|---|
Line 5: | Line 5: | ||
\\ | \\ | ||
- | - You want to schedule a backup done via a cron job. | + | - You want to schedule a backup |
- | - You want the script initiated from, and stored in a safe location | + | - You want the script initiated from, and stored in a safe location |
- You do not wish to install SFTP just for these backups. | - You do not wish to install SFTP just for these backups. | ||
Line 49: | Line 49: | ||
\\ | \\ | ||
- | - Command line arguments: backup directory, id-file and router (as IP address). \\ If provided, these will be used. Otherwise, the defaults will apply \\ (such Router IP from "ip r"). | + | - Command line arguments: backup directory, id-file and router (as IP address). \\ If provided, these will be used. Otherwise, the defaults will apply \\ (search |
- Sometimes tar may fail. You can solve this by just cleaning. The next \\ cron run may do that. | - Sometimes tar may fail. You can solve this by just cleaning. The next \\ cron run may do that. | ||
- All earlier backups from the same day are abandoned. | - All earlier backups from the same day are abandoned. | ||
Line 104: | Line 104: | ||
# take date from localhost (i.e. backupserver) into backup filename | # take date from localhost (i.e. backupserver) into backup filename | ||
| | ||
+ | |||
pushd ${DIR2BACKUP} > /dev/null | pushd ${DIR2BACKUP} > /dev/null | ||