TARPATCH(1) General Commands Manual TARPATCH(1)

tarpatch
apply binary delta to directory tree

tarpatch [-m mtree] [-r rollbacktar] delta

The tarpatch utility verifies and applies the changes in a delta archive delta computed by tardiff(1) to the directory tree rooted at the working directory.

tarpatch does not delete files — it only creates new ones or modifies existing ones. Use another tool such as postinstall(8) to delete files that are no longer needed.

The following options are supported:

mtree
Specify a relative path inside the tree where an mtree(1) file describing the tree resides. This should match the -m option passed to tardiff(1), in order to verify that the mtree file itself was correctly updated.
rollbacktar
Before changing anything, either extract or create a rollback archive at rollbacktar of all files that are modified by the delta archive.

With the -r option, tarpatch is idempotent. Additionally, the patch can be rolled back by extracting rollbacktar with tar(1). Note: tarpatch will first create the file ⟨rollbacktar.tmp, and then rename it to rollbacktar, in order to create rollbacktar atomically in case of interruption.

BSPATCH
bspatch(1) program.
MTREE
mtree(1) program.
TAR
tar(1) program. Note: Must be bsdtar.

bspatch(1), mtree(1), tar(1), tardiff(1)

tarpatch is not atomic — programs running at the same time may see the directory tree only partially patched, and, if writing to the tree, may corrupt the rollback archive. Consider working in a zfs(8) clone.

tarpatch is new and may have bugs. Take and test backups regularly.

January 5, 2021 NetBSD 9.1_STABLE