aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/scripts/backup-sims.sh
diff options
context:
space:
mode:
authorDavid Walter Seikel2016-11-27 23:53:51 +1000
committerDavid Walter Seikel2016-11-27 23:53:51 +1000
commitb4fdb5524411dc51ba60713387d87f532f1d6d02 (patch)
tree589b872e7d52b875dffddfa9c1720da4a95d36d2 /scripts/backup-sims.sh
parentBreak out common script bits into their own file. (diff)
downloadopensim-SC_OLD-b4fdb5524411dc51ba60713387d87f532f1d6d02.zip
opensim-SC_OLD-b4fdb5524411dc51ba60713387d87f532f1d6d02.tar.gz
opensim-SC_OLD-b4fdb5524411dc51ba60713387d87f532f1d6d02.tar.bz2
opensim-SC_OLD-b4fdb5524411dc51ba60713387d87f532f1d6d02.tar.xz
Sleep between backups based on size of the backup file. Poor mans "wait for it to finish" guess.
Diffstat (limited to '')
-rwxr-xr-xscripts/backup-sims.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/backup-sims.sh b/scripts/backup-sims.sh
index 2d174b1..a449e41 100755
--- a/scripts/backup-sims.sh
+++ b/scripts/backup-sims.sh
@@ -9,9 +9,11 @@ do
9 if [ -e "${PRGDIR}/../config/${j}" ] 9 if [ -e "${PRGDIR}/../config/${j}" ]
10 then 10 then
11 cd ${PRGDIR}/../config/$j 11 cd ${PRGDIR}/../config/$j
12 # Find out the size of the last backup, base our later sleep on that, but do it now before backup-sim packs it away.
13 sizeSleep=`sleepPerSize o "$(getSimName ${i})"`
12 ./backup-sim 14 ./backup-sim
13 # Sleep for a while, so that there is plenty of time to do the backup, 15 # Sleep for a while, so that there is plenty of time to do the backup,
14 # and we are not keeping the computer very busy if there are lots of sims. 16 # and we are not keeping the computer very busy if there are lots of sims.
15 sleep 200 17 sleep ${sizeSleep}
16 fi 18 fi
17done 19done