diff --git a/docs/40_Usage/10_Backup.md b/docs/40_Usage/10_Backup.md new file mode 100644 index 0000000000000000000000000000000000000000..1ffc77487d329a22be36f816854f116c45916210 --- /dev/null +++ b/docs/40_Usage/10_Backup.md @@ -0,0 +1,41 @@ +``` +# ./backup.sh -? + + ___ ___ ___ ___ _______ __ + | | Y | | | _ .---.-.----| |--.--.--.-----. + |. |. |. | |. 1 | _ | __| <| | | _ | + |. |. \_/ |. |___ |. _ |___._|____|__|__|_____| __| + |: |: | |: 1 | |: 1 \ |__| + |::.|::.|:. |::.. . | |::.. . / + `---`--- ---`-------' `-------' + +_______________________________________________________________________________ ___ __ _ + +Param: show help + +START A BACKUP + +This script starts + - the database backups and creates dumps locally + - the file backup (using restic or duplicity) + +SYNTAX: + + backup.sh [OPTIONS] + + default: no parameter: + +OPTIONS: + + -d, --dryrun just show infos, do not start a backup + -h, --help Show this help + + The following parameters force the backup type (if using duplicity): + -a, --auto force auto + -o, --older duplicity type=auto: repeat full backup if last full + backup is older than ... like "1M" for 1 month + -f, --full force full backup (if supported) + -i, --inc force incrmenental backup + +``` + diff --git a/docs/40_Usage/10_Database.md b/docs/40_Usage/20_Database.md similarity index 100% rename from docs/40_Usage/10_Database.md rename to docs/40_Usage/20_Database.md diff --git a/docs/40_Usage/30_Filetransfer.md b/docs/40_Usage/30_Filetransfer.md new file mode 100644 index 0000000000000000000000000000000000000000..80202c4ab6bde06aede89ea4c5f5ec1a2ec3a75c --- /dev/null +++ b/docs/40_Usage/30_Filetransfer.md @@ -0,0 +1,33 @@ +``` +# ./transfer.sh -? + + ___ ___ ___ ___ _______ __ + | | Y | | | _ .---.-.----| |--.--.--.-----. + |. |. |. | |. 1 | _ | __| <| | | _ | + |. |. \_/ |. |___ |. _ |___._|____|__|__|_____| __| + |: |: | |: 1 | |: 1 \ |__| + |::.|::.|:. |::.. . | |::.. . / + `---`--- ---`-------' `-------' + + ,--. ,---. + ,-' '-.,--.--. ,--,--.,--,--, ,---. / .-' ,---. ,--.--. + '-. .-'| .--'' ,-. || \( .-' | `-,| .-. :| .--' + | | | | \ '-' || || |.-' `)| .-'\ --.| | + `--' `--' `--`--'`--''--'`----' `--' `----'`--' +_______________________________________________________________________________ ___ __ _ + +HELP: + + Transfer local files to a backup target. + + target sftp://imlbackup@storage-connector.iml.unibe.ch//netshare/restic-backup + backup tool restic + + PARAMETERS: + transfer.sh - incremental backup + transfer.sh full - full backup + transfer.sh dumps - transfer local dumps only + transfer.sh prune - cleanup backup data only (no backup) + transfer.sh help - show this help (works with -h and -? too) + +``` diff --git a/docs/40_Usage/40_Cronjob.md b/docs/40_Usage/40_Cronjob.md new file mode 100644 index 0000000000000000000000000000000000000000..b17489c2de4fc62255802a1053b14ad9eb57fb98 --- /dev/null +++ b/docs/40_Usage/40_Cronjob.md @@ -0,0 +1,17 @@ +To start a daily backup at 23:03: + +```shell +$ cat /etc/cron.d/client-backup +3 23 * * * root /opt/imlbackup/client/backup.sh >/dev/null 2>&1 +``` + +... or with using the cronwrapper + +see <https://github.com/axelhahn/cronwrapper> + +TTL is 1440 for 1440 min = 1d + +```shell +$ cat /etc/cron.d/client-backup +3 23 * * * root /usr/local/bin/cronwrapper.sh 1440 /opt/imlbackup/client/backup.sh 'iml-backup' +``` diff --git a/docs/40_Usage/50_Restore_files.md b/docs/40_Usage/50_Restore_files.md new file mode 100644 index 0000000000000000000000000000000000000000..48a420b20c62f93c238cde1394df7d4b9b5ffbe6 --- /dev/null +++ b/docs/40_Usage/50_Restore_files.md @@ -0,0 +1,9 @@ +TODO + +To start an interactive tool: + +`./restore.sh` + +or + +`./restore.sh [backupped_folder]` diff --git a/docs/40_Usage/60_Restore_a_database.md b/docs/40_Usage/60_Restore_a_database.md new file mode 100644 index 0000000000000000000000000000000000000000..a0039e0b7db1c17929d207c817ffce4ecdc599d4 --- /dev/null +++ b/docs/40_Usage/60_Restore_a_database.md @@ -0,0 +1,9 @@ +TODO + +`localdump.sh reatore [type]` + +i.e. + +`localdump.sh reatore mysql` + +to start interactive restore. \ No newline at end of file