eole-mariadb/schedule/scripts/mariadb

20 lines
328 B
Plaintext
Raw Normal View History

#!/bin/bash
set -e
DESC="Exportation des bases MariaDB"
. /usr/share/eole/schedule/config.sh
MYSQLSAVDIR=$SAVDIR/sql
OPTION="--lock-tables"
2020-11-19 10:15:32 +01:00
if [[ -d ${MYSQLSAVDIR} ]]
then
rm -rf ${MYSQLSAVDIR}
mkdir -p ${MYSQLSAVDIR}
fi
2019-06-07 14:47:57 +02:00
mariabackup --defaults-file=/etc/mysql/debian.cnf --backup --target-dir=$MYSQLSAVDIR
2020-11-19 10:15:32 +01:00
exit $?