#743 Issue closed: NETFS Tar Incremental restore fails with message « Backup archive '' not found » if BACKUP_PROG_COMPRESS is not gzip

Labels: bug, fixed / solved / done

DamienGombaultRecia opened issue at 2015-12-16 12:55:

Hi.

I have set in local.conf :
BACKUP_PROG_COMPRESS_OPTIONS="--bzip2"
BACKUP_PROG_COMPRESS_SUFFIX=".bz2"
Incremental archives are now bziped and suffixed with .bz2.

In file /usr/share/rear/prep/NETFS/default/07_set_backup_archive.sh, line 14 :
for i in $(ls ${BUILD_DIR}/outputfs/${NETFS_PREFIX}/*.tar.gz); do restorearchive=$i;done
setting restorearchive variable is hardcoded with .tar.gz.

Restore fails because it does not find my .tar.bz2 files.
I think .tar.gz should be replaced with ${BACKUP_PROG_SUFFIX}${BACKUP_PROG_COMPRESS_SUFFIX}

Thank you.

gdha commented at 2015-12-17 07:40:

@DamienGombaultRecia Thank you for reporting this. I'll check it myself when I have a bit of spare time (not this week anymore)

gdha commented at 2015-12-24 10:46:

@DamienGombaultRecia could you verify the fix is correct?

DamienGombaultRecia commented at 2015-12-24 11:02:

Hi. The patch looks good.
I'm on holidays, I will test it in January.
Happy christmas :)

gdha commented at 2016-01-07 16:00:

@DamienGombaultRecia A kind reminder to run a quick test - thx

DamienGombaultRecia commented at 2016-01-07 16:02:

Hi.
I'll try to test it tomorrow.

DamienGombaultRecia commented at 2016-01-08 11:09:

Hi.
The fix is not complete and does not work.
I did not notice before but the verify/NETFS/default/07_set_backup_archive.sh file should be modified the same way, then it works.

gdha commented at 2016-01-13 10:37:

@DamienGombaultRecia Thank you for catching this! I just fixed it as well. Please verify and give me feedback.

DamienGombaultRecia commented at 2016-01-18 15:35:

The patch now works :)
Thank you.


[Export of Github issue for rear/rear.]