projects
/
zfs-ubuntu
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9eb1c32
)
Need to be root to destroy snapshots
author
Alan J. Pippin
<alan@pippins.net>
Fri, 20 Aug 2021 22:03:56 +0000
(16:03 -0600)
committer
Alan J. Pippin
<ajp@pippins.net>
Fri, 20 Aug 2021 22:03:56 +0000
(16:03 -0600)
Change-Id: I59d7cc59785b99219af3bdf1163461e738ee1d9c
zfs-rm-all-snaps
patch
|
blob
|
history
diff --git
a/zfs-rm-all-snaps
b/zfs-rm-all-snaps
index 868bba53dae88f376b18660cb81e71d2165a1a73..5bc06096b25dad491ff1eafe262ea61fc8d1f99b 100755
(executable)
--- a/
zfs-rm-all-snaps
+++ b/
zfs-rm-all-snaps
@@
-29,7
+29,7
@@
read
for snap in `zfs list -t snapshot 2>/dev/null | grep "^$zfs_pool" | grep "$snap_pattern" | awk '{print $1}'`; do
echo " destroying snapshot: $snap"
- zfs destroy "$snap" 2>/dev/null
+
sudo
zfs destroy "$snap" 2>/dev/null
done
echo "-> Snapshots removed"