You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Current documentation says that Borg doesn't preserve...
...representation of the holes in a sparse file. Archive creation has no special support for sparse files, holes are backed up as (deduplicated and compressed) runs of zero bytes. Archive extraction has optional support to extract all-zero chunks as holes in a sparse file.
Now suppose that the user has a huge (16TB on ext4) sparse file. While it will be stored efficiently in the repo, backup operation will require reading, chunking and MACing all the data.
Supporting efficient reading of sparse files during backup, but not storing information about holes in the repo is not a solution either: now suppose the user also has somewhat big file that is not sparse, but has lots of zero blocks (perhaps the user did fallocate() to ensure the space is available when she writes to file later, maybe she even defragmented the file to meet some real-time requirements).
Borg will backup both files the same way and on restore the user will have the choice: either restore all with holes (thus breaking fallocate()-type files), or restore all as-is, thus running out of space.
Please implement true support for sparse files with lseek(SEEK_DATA) and lseek(SEEK_HOLE) (avoid common mistake of assuming that file begins with data).
The text was updated successfully, but these errors were encountered:
kroki
changed the title
True support for space files is essential
True support for sparse files is essential
Dec 18, 2019
This issue is related to #2562, but not the same.
Current documentation says that Borg doesn't preserve...
Now suppose that the user has a huge (16TB on ext4) sparse file. While it will be stored efficiently in the repo, backup operation will require reading, chunking and MACing all the data.
Supporting efficient reading of sparse files during backup, but not storing information about holes in the repo is not a solution either: now suppose the user also has somewhat big file that is not sparse, but has lots of zero blocks (perhaps the user did
fallocate()
to ensure the space is available when she writes to file later, maybe she even defragmented the file to meet some real-time requirements).Borg will backup both files the same way and on restore the user will have the choice: either restore all with holes (thus breaking
fallocate()
-type files), or restore all as-is, thus running out of space.Please implement true support for sparse files with
lseek(SEEK_DATA)
andlseek(SEEK_HOLE)
(avoid common mistake of assuming that file begins with data).The text was updated successfully, but these errors were encountered: