From ca5c005e882261dcbe9542fd14f8d6177ab56dd9 Mon Sep 17 00:00:00 2001 From: Niklas Meyer Date: Mon, 11 Jul 2022 21:14:01 +0200 Subject: [PATCH] Fixed crontab Backup failure (missing Path Variable) --- docs/backup_restore/b_n_r-backup.de.md | 2 ++ docs/backup_restore/b_n_r-backup.en.md | 2 ++ 2 files changed, 4 insertions(+) diff --git a/docs/backup_restore/b_n_r-backup.de.md b/docs/backup_restore/b_n_r-backup.de.md index d3d185266..997510df0 100644 --- a/docs/backup_restore/b_n_r-backup.de.md +++ b/docs/backup_restore/b_n_r-backup.de.md @@ -38,6 +38,7 @@ MAILCOW_BACKUP_LOCATION=/opt/backup /opt/mailcow-dockerized/helper-scripts/backu Sie können das Backup-Skript regelmäßig über einen Cronjob laufen lassen. Stellen Sie sicher, dass `BACKUP_LOCATION` existiert: ``` +PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin 5 4 * * * cd /opt/mailcow-dockerized/; MAILCOW_BACKUP_LOCATION=/mnt/mailcow_backups /opt/mailcow-dockerized/helper-scripts/backup_and_restore.sh backup mysql crypt redis --delete-days 3 ``` @@ -82,6 +83,7 @@ mkdir -p /external_share/backups/backup_script Cronjobs erstellen: ``` +PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin 25 1 * * * rsync -aH --delete /opt/mailcow-dockerized /external_share/backups/mailcow-dockerized 40 2 * * * rsync -aH --delete /var/lib/docker/volumes /external_share/backups/var_lib_docker_volumes 5 4 * * * cd /opt/mailcow-dockerized/; BACKUP_LOCATION=/external_share/backups/backup_script /opt/mailcow-dockerized/helper-scripts/backup_and_restore.sh backup mysql crypt redis --delete-days 3 diff --git a/docs/backup_restore/b_n_r-backup.en.md b/docs/backup_restore/b_n_r-backup.en.md index 50d29f0ce..e3d9926f9 100644 --- a/docs/backup_restore/b_n_r-backup.en.md +++ b/docs/backup_restore/b_n_r-backup.en.md @@ -38,6 +38,7 @@ MAILCOW_BACKUP_LOCATION=/opt/backup /opt/mailcow-dockerized/helper-scripts/backu You can run the backup script regularly via cronjob. Make sure `BACKUP_LOCATION` exists: ``` +PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin 5 4 * * * cd /opt/mailcow-dockerized/; MAILCOW_BACKUP_LOCATION=/mnt/mailcow_backups /opt/mailcow-dockerized/helper-scripts/backup_and_restore.sh backup mysql crypt redis --delete-days 3 ``` @@ -82,6 +83,7 @@ mkdir -p /external_share/backups/backup_script Create cronjobs: ``` +PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin 25 1 * * * rsync -aH --delete /opt/mailcow-dockerized /external_share/backups/mailcow-dockerized 40 2 * * * rsync -aH --delete /var/lib/docker/volumes /external_share/backups/var_lib_docker_volumes 5 4 * * * cd /opt/mailcow-dockerized/; BACKUP_LOCATION=/external_share/backups/backup_script /opt/mailcow-dockerized/helper-scripts/backup_and_restore.sh backup mysql crypt redis --delete-days 3