-
-
Save alexjj/4de71ddfae05e974c829 to your computer and use it in GitHub Desktop.
zfs list -H -o name -t snapshot | xargs -n1 zfs destroy |
I tried with sudo and even sudo -s but it didn't work
I tried on Ubuntu 20.04 but still it doesn't work
Switch to root first. sudo doesn't travel down pipes without tees or something.
sudo -i
zfs list -H -o name -t snapshot | xargs -n1 zfs destroy
zfs list -H -o name -t snapshot | xargs -n1 sudo zfs destroy
works for me on 20.04
Recommend to be aware that unless specified a dataset ALL snapshots gets deleted. here is a USER specific example on Ubuntu 20.04:
$ sudo zfs list -H -o name -t snapshot rpool/USERDATA/example | sudo xargs -n1 zfs destroy
You can also zfs destroy rpool@%
.
foo%bar
denotes a range of snapshots from foo
to bar
; omitting either uses the earliest or latest snapshot respectively.
thanks! works after sudo su
So guys a little help here, I deleted all the snapshots cause they were taking up all the space, it worked fine for a while, but now Ubuntu will not boot up showing a sys error "Failed to MARK current zsys boot as successful".Any solutions
I suspect it's how ubuntu does things with zsys and you'd be better off asking on ubuntu forums.
Are you root?