A set of scripts for running Duplicacy on Unix systems
This is a set of scripts that can be used to manage running
Duplicacy(GitHub)
on Unix systems. They were developed and tested under Linux but
should work in any environment that complies with POSIX except Windows
(see note below).
Release 1.3: The duplicacy
binary that was manually installed in
the top-level directory per the instructions from earlier versions
is no longer used and may be removed.
These scripts download and use the Duplicacy binary from Gilbert
Chen’s release
page on GitHub.
The license for Duplicacy imposes some restrictions on its use.
Please abide by them.
Limitations in the current implementation of Duplicacy and the fact
that Windows does not handle symbolic linking in a POSIX-like way
makes these scripts unsuitable for that environment.
Your system must have the following installed:
To install this package on your system:
Clone this repository: git clone https://github.com/markfeit/duplicacy-scripts.git
cd duplicacy-scripts
Select a location where duplicacy-scripts, the Duplicacy
configuration, its cache and log files will be kept. This location
will be referred to as $DEST
. The default is /opt/duplicacy
.
Select the location which will form the root of the volume(s) to be
backed up. This will be referred to as $ROOT
. The default is /
,
which is suitable for most systems. (Specific parts of the filesystem
may be included or excluded using Duplicacy’s filter mechanism.)
Become root
and execute:
make install
to install using the defaultsmake DEST=$DEST ROOT=$ROOT install
to install using other directories.Installation may be done as any other user, but be aware that this
will limit the set of files backed up to those the user can read. In
addition to installing these scripts, a .duplicacy
file will be
placed in $ROOT
.
Set up Duplicacy by placing a preferences
and optional filter
file
in $DEST/prefs
Samples are provided in the prefs
directory of the
sources. These files are not installed by default.
Set up the scripts by editing $DEST/etc/settings
. Note that ifCONFIG_AUTO_UPDATE
is enabled:
$DEST/etc/settings-update
rather than overwriting settings
.At this point, backups and maintenance will be done automatically by
cron.
Backups are run at 00:45 local time each morning. If there is another
backup running (common when there is a long initial backup running),
the newer backup will be aborted.
Logs of what happens during each backup and other matinenance
activities are stored in $DEST/var/log
. The latest logs or those
for a specific date can be retrieved and read with $DEST/bin/logs
.
To restore files, execute $DEST/bin/restore
. Detailed help may be
obtained with the --help
switch.
Daily (03:00):
etc/prune
.CONFIG_LOG_LIFE
in settings.CONFIG_CACHE_LIFE
in settings.$DEST/etc/settings
).Weekly (Sunday at 03:15):
Fossilize and remove chunks that are no longer referenced.
Check integrity. This verifies that all chunks that should be
present and attempts to resurrect missing chunks from fossils if
possible. There is no attempt to download and verify the contents
of the chunks. (Not implemented yet.)
Monthly (First Sunday at 03:30):