diff --git a/NEWS b/NEWS index db012930..cc0d580f 100644 --- a/NEWS +++ b/NEWS @@ -1,5 +1,5 @@ 1.9.13.dev0 - * + * #1001: Fix a ZFS error during snapshot cleanup. 1.9.12 * #1005: Fix the credential hooks to avoid using Python 3.12+ string features. Now borgmatic will diff --git a/borgmatic/hooks/data_source/zfs.py b/borgmatic/hooks/data_source/zfs.py index 2ca53c18..9cb77587 100644 --- a/borgmatic/hooks/data_source/zfs.py +++ b/borgmatic/hooks/data_source/zfs.py @@ -420,7 +420,7 @@ def remove_data_source_dumps(hook_config, config, borgmatic_runtime_directory, d continue if not dry_run: - shutil.rmtree(snapshots_directory) + shutil.rmtree(snapshot_mount_path, ignore_errors=True) # Destroy snapshots. full_snapshot_names = get_all_snapshots(zfs_command)