Added option to disable database locking

To make it work with newer mariadb versions.
This commit is contained in:
kolaente 2018-11-23 18:09:28 +01:00 committed by GitHub
parent c7128324af
commit 936f3b5fd3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -187,7 +187,7 @@ for row in $(echo "${backup_hosts_file}" | jq -r '.[] | @base64'); do
# Do the backup
echo "Backing up $db_host"
mysqldump --all-databases -u ${db_user} -p${db_pw} -h ${db_host} --port ${db_port} > $backup_folder/"$date"/${db_host}_all-databases.sql
mysqldump --all-databases -u ${db_user} -p${db_pw} -h ${db_host} --port ${db_port} -lock-tables=0 > $backup_folder/"$date"/${db_host}_all-databases.sql
if [ $? -eq 0 ]; then
echo "Success."
else