Xbackup on large DB decompress option

I am looking for a better way of doing this…

Right now I have a 10TB DB in two physically geographical locations. I run nightly backups on one of the nodes that has a 50TB backup partition
I leverage the compress option on the backups and everything works fine (no issues with the backups)

The problem I ran into is with the system that the backups were NOT on had issues and needed to be rebuilt.

As the non backup system does not have a /backup drive with a ton of space I copied the files to the main mysql data dir (I have a /data /logs and /tmp)

When running the decompress option I run out of drive space as the compressed files and the datafiles are on the same mount point

Question:
Does an option exist for after the file is decompressed delete the compressed file? (for each thread as I am using about 30 threads)

1 Like

Hi @meyerder

I belive you are looking for –remove-original option:

marcelo@marce-bld:/work/pxb/src/8.0$ xtrabackup --decompress --remove-original --target-dir=/tmp/backup
xtrabackup: recognized client arguments: --user=root --decompress=1 --remove-original=1 --target-dir=/tmp/backup
xtrabackup version 8.0.26-18 based on MySQL server 8.0.26 Linux (x86_64) (revision id: 56a46198d3e)
210910 09:16:03 [01] decompressing ./xtrabackup_binlog_info.qp
210910 09:16:03 [01] removing ./xtrabackup_binlog_info.qp
210910 09:16:03 [01] decompressing ./ibdata1.qp
210910 09:16:03 [01] removing ./ibdata1.qp
210910 09:16:03 [01] decompressing ./sys/sys_config.ibd.qp
210910 09:16:03 [01] removing ./sys/sys_config.ibd.qp
210910 09:16:03 [01] decompressing ./binlog.index.qp
210910 09:16:03 [01] removing ./binlog.index.qp
1 Like