Increase network connections to B2
This commit is contained in:
@@ -31,6 +31,8 @@ BACKUP_TAG=systemd.timer
|
|||||||
# B2_ACCOUNT_ID, B2_ACCOUNT_KEY, RESTIC_REPOSITORY etc.
|
# B2_ACCOUNT_ID, B2_ACCOUNT_KEY, RESTIC_REPOSITORY etc.
|
||||||
source /etc/restic/b2_env.sh
|
source /etc/restic/b2_env.sh
|
||||||
|
|
||||||
|
# How many network connections to set up to B2. Default is 5.
|
||||||
|
B2_CONNECTIONS=50
|
||||||
|
|
||||||
# NOTE start all commands in background and wait for them to finish.
|
# NOTE start all commands in background and wait for them to finish.
|
||||||
# Reason: bash ignores any signals while child process is executing and thus my trap exit hook is not triggered.
|
# Reason: bash ignores any signals while child process is executing and thus my trap exit hook is not triggered.
|
||||||
@@ -49,6 +51,7 @@ restic backup \
|
|||||||
--verbose \
|
--verbose \
|
||||||
--one-file-system \
|
--one-file-system \
|
||||||
--tag $BACKUP_TAG \
|
--tag $BACKUP_TAG \
|
||||||
|
--option b2.connections=$B2_CONNECTIONS \
|
||||||
$BACKUP_EXCLUDES \
|
$BACKUP_EXCLUDES \
|
||||||
$BACKUP_PATHS &
|
$BACKUP_PATHS &
|
||||||
wait $!
|
wait $!
|
||||||
@@ -69,6 +72,7 @@ wait $!
|
|||||||
# Remove old data not linked anymore.
|
# Remove old data not linked anymore.
|
||||||
# See restic-prune(1) or http://restic.readthedocs.io/en/latest/060_forget.html
|
# See restic-prune(1) or http://restic.readthedocs.io/en/latest/060_forget.html
|
||||||
restic prune \
|
restic prune \
|
||||||
|
--option b2.connections=$B2_CONNECTIONS \
|
||||||
--verbose &
|
--verbose &
|
||||||
wait $!
|
wait $!
|
||||||
|
|
||||||
|
|||||||
@@ -16,9 +16,11 @@ exit_hook() {
|
|||||||
trap exit_hook INT TERM
|
trap exit_hook INT TERM
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
source /etc/restic/b2_env.sh
|
source /etc/restic/b2_env.sh
|
||||||
|
|
||||||
|
# How many network connections to set up to B2. Default is 5.
|
||||||
|
B2_CONNECTIONS=50
|
||||||
|
|
||||||
# Remove locks from other stale processes to keep the automated backup running.
|
# Remove locks from other stale processes to keep the automated backup running.
|
||||||
# NOTE nope, dont' unlock liek restic_backup.sh. restic_backup.sh should take preceedance over this script.
|
# NOTE nope, dont' unlock liek restic_backup.sh. restic_backup.sh should take preceedance over this script.
|
||||||
#restic unlock &
|
#restic unlock &
|
||||||
@@ -26,5 +28,6 @@ source /etc/restic/b2_env.sh
|
|||||||
|
|
||||||
# Check repository for errors.
|
# Check repository for errors.
|
||||||
restic check \
|
restic check \
|
||||||
|
--option b2.connections=$B2_CONNECTIONS \
|
||||||
--verbose &
|
--verbose &
|
||||||
wait $!
|
wait $!
|
||||||
|
|||||||
Reference in New Issue
Block a user