Skip to content

DHS 0.1.2 — deduplicated files restore correctly

Pre-release
Pre-release

Choose a tag to compare

@Necta14 Necta14 released this 03 Sep 11:19
· 17 commits to main since this release

This is a pre-release, and it fixes a data-integrity defect in the two before it.

Fixed

When two identical compressible files were backed up, the second one was written into the
package with no reference to the stored bytes. The package then verified as perfectly intact, and
restoring that single file failed with corrupt data and wrote nothing. Refusing to write was the
right behaviour, but the copy was gone from the package.

If you hold a package built with 0.1.0 or 0.1.1 and it contains duplicate files, rebuild it with
this version.
dhs list <package> --all marks duplicates with (dup). A package with none is
unaffected.

The cause: a duplicate copied the original's block references at the moment it was added, but the
original's bytes were often still sitting in an open solid block, so the references that arrived
later reached the original alone. Files that are stored rather than compressed, images and other
incompressible data, were never affected, which is exactly why the test suite missed it: its only
duplicate fixture was a JPEG. The suite now covers a compressible duplicate and asserts the index
entry carries block references at all.

Found by running the Windows binary under Wine with two identical binary-class files. It is not a
Windows defect; a package written on Linux lost the same file.

Everything else

Unchanged from 0.1.1. The file core, scan backup verify list restore, is tested; the
application manifest and app detection are still not written. The Windows binary now has some
exposure through Wine, including a full backup and restore cycle, but it has still not run on real
Windows.

Install

Windows, in PowerShell:

irm https://dhs-suite.vercel.app/install.ps1 | iex

It picks the build for your processor, checks it against the sums published here, unpacks it under
your own profile and puts it on your PATH. No administrator rights and nothing left running.

Linux: take the .deb, the .rpm, the AppImage or the tarball below. On Arch, dhs-cli and
dhs-gui build from the recipe in packaging/aur/.

sha256sum -c SHA256SUMS --ignore-missing

Tested this release: the .deb installs on Debian and Ubuntu, the .rpm on Fedora, Rocky and
openSUSE, the tarball runs on Alpine against musl, the AppImage runs without FUSE, and both AUR
packages build and install on Arch.