borg icon indicating copy to clipboard operation
borg copied to clipboard

diff against existing files

Open anarcat opened this issue 9 years ago • 4 comments

the diff command (#177) is great in finding out what changed between different archives. however, it would also be useful to diff against existing files. i know that you can use FUSE to mount an archive and use external tools to diff against that, but it seems to me there are optimizations that could be done with an internal diff command. for example, one could diff an individual file and avoid the overhead of doing the FUSE mount and looking down the directory tree...

There was a discussion on the mailing list recently that touched on this subject: https://mail.python.org/pipermail/borgbackup/2016q2/000202.html

anarcat avatar Apr 22 '16 17:04 anarcat

borg lists --format option also supports common hashes, which could get the job done in many cases. Especially if one just wants to run shaXXXsum on some files.

enkore avatar Apr 22 '16 17:04 enkore

note: still no progress on that one, although in the upcomming 1.1 release you will be able to diff between already backed-up archives.

To sum it up.

  1. diff against existing files - may be possible in one of 3 ways: 1.1. use borg create -v --dry-run ... should work - I could not make it work - it ran but no diffs appeared on console 1.2. borg mount and diff between live FS and the mount - painfully slow... but still doable - at least if u can mount the archives on localhost somehow (hard / impossible if your borg backups are remotely saved) 1.3. just backup the live FS to create a new archive - and then diff this new one against the one before it using the latest git dev borg that is 1.1-dev-something. NOTE: borg diff does not exist in latest stable borg = 1.0.6, you need to install it via https://borgbackup.readthedocs.io/en/stable/installation.html#git-installation

and then from within the virtualenv where you have borg 1.1+ you can borg diff.... caveat 1: u will need to use sudo caveat 2: u will need to use sudo + the full path to the borg executable in the venv...

DrupaListo-com avatar Aug 01 '16 12:08 DrupaListo-com

Is this issue completely abandoned?

mortee avatar Nov 22 '23 20:11 mortee

@mortee Issue is not closed.

But OTOH other stuff has higher priority and there are limited developer resources.

ThomasWaldmann avatar Nov 22 '23 21:11 ThomasWaldmann