Skip to content

possible loss of backup archives when following example in documentations with prune command #241

Description

@bedros

in the automatic backup example and at the bottom there's a prune command as follows

borg prune -v $REPOSITORY --keep-daily=7 --keep-weekly=4 --keep-monthly=6

however, with backup of multiple machines, and one machine has been disconnected for more than 6 months, such as a dead hard drive, the user will lose archives from all machines that are not backed up in last 6 months when issuing the above prune command from any machine, and the user will ultimately use the dead machine backup permanently; I've done dummy testing and verified that older archives from older machines are removed.

after looking into the documentation, I found the perfect solution which is to add --prefix to the prune command as follows

borg prune -v $REPOSITORY --keep-daily=7 --keep-weekly=4 --keep-monthly=6 --prefix=hostname

such a prune command will only delete old archives of the current machine, and will leave archives of other machines untouched

please update the example by adding the --prefix=hostname

Thanks,

Bedros

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions