diff --git a/docs/quickstart.rst b/docs/quickstart.rst index 0c29212..c297be2 100644 --- a/docs/quickstart.rst +++ b/docs/quickstart.rst @@ -19,4 +19,32 @@ If you just want to try borg-import with minimal setup: python -m venv env source env/bin/activate pip install -e . - borg-import --help \ No newline at end of file + borg-import --help + +Import rsync snapshots +---------------------- + +For example, if an rsync-with-hard-links backup stores one snapshot per +directory:: + + /srv/rsync-backups/ + |-- snapshot-2026-08-28/ + `-- snapshot-2026-08-29/ + +first initialize the destination repository, then import the snapshots:: + + borg init --encryption=repokey /srv/borg-repository + borg-import rsynchl /srv/rsync-backups /srv/borg-repository + +The repository path must be absolute (or a remote repository specification). +``borg-import`` creates one archive per snapshot directory, using the directory +name as the archive name and its modification time as the archive timestamp. +Confirm the imported archives with:: + + borg list --short /srv/borg-repository + +During an import, each snapshot directory is temporarily renamed within the +snapshot root so Borg's files cache can recognize unchanged files efficiently. +The directory is moved back even if ``borg create`` fails. Test with a copy of +your backup first, and make sure the destination has enough free space before +importing a large backup set.