main_part.include: fix - further more - a bug in script output.

This commit is contained in:
Christoph 2020-06-25 10:30:18 +02:00
parent 2330f736f2
commit 2d68b36d60

View File

@ -291,7 +291,7 @@ if [ "$found" = "true" -o "$pgsql_backup" = "true" -o "$mysql_backup" = "true"
echolog "\t${_val_arr[0]}: ${_val_arr[1]}"
$ssh ${ssh_user}@${srcHost} "$sudo -u ${_val_arr[0]} ${_val_arr[1]}" > /dev/null 2> $err_Log
if [[ "$?" -ne 0 ]]; then
echolog "\t[ERROR] Executing command failed.\n $(cat "$err_Log")
echolog "\t[ERROR] Executing command failed.\n $(cat "$err_Log")"
fi
done
@ -364,7 +364,7 @@ if [ "$found" = "true" -o "$pgsql_backup" = "true" -o "$mysql_backup" = "true"
echolog "\t${_val_arr[0]}: ${_val_arr[1]}"
$ssh ${ssh_user}@${srcHost} "$sudo -u ${_val_arr[0]} ${_val_arr[1]}" > /dev/null 2> $err_Log
if [[ "$?" -ne 0 ]]; then
echolog "\t[ERROR] Executing command failed.\n $(cat "$err_Log")
echolog "\t[ERROR] Executing command failed.\n $(cat "$err_Log")"
fi
done