Download only "xtrabackup_checkpoints" and "xtrabackup_info" files from S3

Hello Percona team,

currently, we are backing up some MySQL databases via Xtrabackup (8.0) to S3 (xtrabackup + xbcloud) and also saving the files “xtrabackup_checkpoints” and “xtrabackup_info” locally. But if there are issues with the server and we loose this local filesystem, which would also destroy both files, we would like a way to manually download those files from S3.

As backups are getting parallelized, it seems these files are being stored in S3 as a file of the “data” type and are broken into multiple parts.

If using AWS CLI to download each part of either “xtrabackup_checkpoints” and “xtrabackup_info”, they seem to be non-readable via cat/vim, for example, as they are saved in S3 as “data” instead of “text”.

Based on this, is it possible to download only these 2 files (“xtrabackup_checkpoints” and “xtrabackup_info”) and merge them into a usable/readable files?

Thanks

Two ways:

mkdir -p /tmp/meta

Option 1:

xbcloud get
–storage=s3
–s3-bucket=
–s3-region=us-west-2
–s3-access-key=
–s3-secret-key=
–s3-endpoint=
–s3-bucket-lookup=path
<BACKUP_NAME> xtrabackup_checkpoints xtrabackup_info
| xbstream -x -v -C /tmp/meta

Option 2:

aws s3 cp --recursive --exclude ‘’ --include 'xtrabackup_checkpoints.’ --include ‘xtrabackup_info.*’
s3:///<BACKUP_NAME>/ ./parts/

cat ./parts/xtrabackup_checkpoints.* ./parts/xtrabackup_info.* | xbstream -x -C /tmp/meta