system/scripts/sh/xtrabackup/run_incremental.sh
Georg 9f60cb8f8b
Init Percona XtraBackup
Signed-off-by: Georg <georg@lysergic.dev>
2021-08-30 21:03:30 +02:00

8 lines
374 B
Bash

#!/bin/sh
DATE=$(date +'%d-%m-%Y')
BASEDATE=$(cat /mnt/backup/xtrabackup/current_basedate)
echo "INCREMENTAL: $DATE"
echo "BASE: $BASEDATE"
/usr/bin/mkdir /mnt/backup/xtrabackup/incremental/$DATE
/opt/xtrabackup/bin/xtrabackup --backup --target-dir=/mnt/backup/xtrabackup/incremental/$DATE --incremental-basedir=/mnt/backup/xtrabackup/full/$BASEDATE |& nc -N 127.0.0.2 2424