Skip to content

Destroying zero-sized snapshots is unexpected and undocumented #33

@adaugherity

Description

@adaugherity

I am using this on FreeBSD (installed via ports) to replace the Solaris auto-snapshot functionality, and it seems like a nice drop-in replacement, except for one thing: some snapshots unexpectedly disappeared, breaking my backup/replication. Example:

$ zfs list
NAME                 USED  AVAIL  REFER  MOUNTPOINT
backup               949G   894G   256K  /export/backup
backup/mysql         422G   894G  75.4G  /export/backup/mysql
backup/www           112G   894G  48.9G  /export/backup/www
...

I replicate this offsite via an incremental zfs send/receive of the root FS (zfs send -R -I snap1 backup@snap2, for details see https://github.com/adaugherity/zfs-backup). The child FSes (mysql, www) change frequently but the root fs does not, and zfs-auto-snapshot was (un)helpfully removing these empty snapshots, preventing me from using them to easily replicate all children.

After looking at the source I discovered the -k option which does exactly what I need, but this is not mentioned in the README, nor is it said that removing empty snapshots is the default (which is a difference from Solaris, AFAICT). I can see why someone might want this (and I don't expect you to change the default just to match Solaris), but it it should be documented.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions