restore backup: don't automatically unmount an ehdd drive

This commit is contained in:
downtownallday
2022-10-14 15:02:44 -04:00
parent 16679aa5ac
commit 1a0b94c878
2 changed files with 14 additions and 9 deletions
+13 -8
View File
@@ -22,14 +22,19 @@ if [ -s /etc/mailinabox.conf ]; then
systemctl stop miabldap-capture
fi
ehdd/umount.sh
code=$?
tries=1
while [ $code -eq 2 -a $tries -le 3 ]; do
echo "Trying again in 10 seconds..."
sleep 10
if [ "$1" != "--no-umount" ]; then
ehdd/umount.sh
code=$?
let tries+=1
done
tries=1
while [ $code -eq 2 -a $tries -le 3 ]; do
echo "Trying again in 10 seconds..."
sleep 10
ehdd/umount.sh
code=$?
let tries+=1
done
else
code=0
fi
exit $code
+1 -1
View File
@@ -62,7 +62,7 @@ if [ ! -d "$backup_files_dir" ]; then
fi
echo "Shutting down services"
ehdd/shutdown.sh || exit 1
ehdd/shutdown.sh --no-umount || exit 1
if [ ! -x /usr/bin/duplicity ]; then
echo "Installing duplicity"