ZFS – Removing all snapshots

To list all of your current snapshots;

zfs list -t snapshot

This is a handy script to remove all snapshots….

for snapshot in `zfs list -H -t snapshot | cut -f 1`
zfs destroy $snapshot

As always : at your own risk. ;)

Leave a Reply

Your email address will not be published. Required fields are marked *