Re: beadm no longer able to destroy, maybe since using OpenZFS

From: Graham Perrin <grahamperrin_at_gmail.com>
Date: Sun, 3 May 2020 18:44:48 +0100
On 03/05/2020 06:05, Graham Perrin wrote:
> After reverting from OpenZFS to ZFS, I was able to destroy two of the 
> boot environments that previously (below, 1st May, OpenZFS) could not 
> be destroyed.
>
> I'm left with at least one BE 'r360237c' that can not be destroyed. Is 
> it ever normal to find a snapshot described as '-'?
>
> root_at_momh167-gjp4-8570p:~ # kldstat | grep zfs
>  2    1 0xffffffff82109000   3a8b40 zfs.ko
> root_at_momh167-gjp4-8570p:~ # date
> Sun May  3 05:59:06 BST 2020

…

> root_at_momh167-gjp4-8570p:~ # beadm destroy r360237c
> Are you sure you want to destroy 'r360237c'?
> This action cannot be undone (y/[n]): y
> Boot environment 'r360237c' was created from existing snapshot
> Destroy '-' snapshot? (y/[n]): y
> cannot destroy 'copperbowl/ROOT/r360237c': filesystem has dependent 
> clones
> use '-R' to destroy the following datasets:
> copperbowl/ROOT/r360237e_at_2020-05-01-17:58:33
> copperbowl/ROOT/r360237e
> copperbowl/ROOT/r357746h
> copperbowl/ROOT/Waterfox

…

I temporarily activated (but did not boot from) an older environment BE 
r357746h, then created and activated r360237f.

Then the previously indestructible r360237c was destroyed successfully:

----

root_at_momh167-gjp4-8570p:~ # beadm list -as
BE/Dataset/Snapshot                            Active Mountpoint Space 
Created

Waterfox
   copperbowl/ROOT/Waterfox                     -      - 314.0M 
2020-03-10 18:24
     r360237f_at_2020-03-20-06:19:45               -      - 1.0G 2020-03-20 
06:19

r357746h
   copperbowl/ROOT/r357746h                     -      - 3.4M 2020-04-08 
09:28
     r360237f_at_2020-04-09-17:59:32               -      - 1.1G 2020-04-09 
17:59

r360237c
   copperbowl/ROOT/r360237c                     -      - 17.0M 
2020-04-29 13:24
     r360237f_at_2020-04-29-13:24:52               -      - 229.0M 
2020-04-29 13:24

r360237e
   copperbowl/ROOT/r360237e                     N      / 680.0K 
2020-05-01 17:58
     r360237f_at_2020-05-03-18:30:25               -      - 440.0K 
2020-05-03 18:30

r360237f
   copperbowl/ROOT/r360237f_at_2020-03-20-06:19:45 -      - 1.0G 2020-03-20 
06:19
   copperbowl/ROOT/r360237f_at_2020-04-09-17:59:32 -      - 1.1G 2020-04-09 
17:59
   copperbowl/ROOT/r360237f_at_2020-04-29-13:24:52 -      - 229.0M 
2020-04-29 13:24
   copperbowl/ROOT/r360237f_at_2020-05-01-17:58:33 -      - 162.0M 
2020-05-01 17:58
   copperbowl/ROOT/r360237f                     R      - 81.7G 
2020-05-03 18:30
   copperbowl/ROOT/r360237f_at_2020-05-03-18:30:25 -      - 440.0K 
2020-05-03 18:30
root_at_momh167-gjp4-8570p:~ # date ; uname -v ; uptime
Sun May  3 18:32:31 BST 2020
FreeBSD 13.0-CURRENT #54 r360237: Fri Apr 24 09:10:37 BST 2020 
root_at_momh167-gjp4-8570p:/usr/obj/usr/src/amd64.amd64/sys/GENERIC-NODEBUG
  6:32PM  up 12:54, 5 users, load averages: 0.48, 0.44, 0.41
root_at_momh167-gjp4-8570p:~ # kldstat | grep zfs
  2    1 0xffffffff82109000   3a8b40 zfs.ko
root_at_momh167-gjp4-8570p:~ # beadm destroy r360237c
Are you sure you want to destroy 'r360237c'?
This action cannot be undone (y/[n]): y
Destroyed successfully
root_at_momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f_at_2020-03-20-06:19:45
cannot destroy 'copperbowl/ROOT/r360237f_at_2020-03-20-06:19:45': snapshot 
has dependent clones
use '-R' to destroy the following datasets:
copperbowl/ROOT/Waterfox
root_at_momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f_at_2020-04-09-17:59:32
cannot destroy 'copperbowl/ROOT/r360237f_at_2020-04-09-17:59:32': snapshot 
has dependent clones
use '-R' to destroy the following datasets:
copperbowl/ROOT/r357746h
root_at_momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f_at_2020-05-01-17:58:33
root_at_momh167-gjp4-8570p:~ # beadm list -as
BE/Dataset/Snapshot                            Active Mountpoint Space 
Created

Waterfox
   copperbowl/ROOT/Waterfox                     -      - 314.0M 
2020-03-10 18:24
     r360237f_at_2020-03-20-06:19:45               -      - 1.0G 2020-03-20 
06:19

r357746h
   copperbowl/ROOT/r357746h                     -      - 3.4M 2020-04-08 
09:28
     r360237f_at_2020-04-09-17:59:32               -      - 1.1G 2020-04-09 
17:59

r360237e
   copperbowl/ROOT/r360237e                     N      / 756.0K 
2020-05-01 17:58
     r360237f_at_2020-05-03-18:30:25               -      - 440.0K 
2020-05-03 18:30

r360237f
   copperbowl/ROOT/r360237f_at_2020-03-20-06:19:45 -      - 1.0G 2020-03-20 
06:19
   copperbowl/ROOT/r360237f_at_2020-04-09-17:59:32 -      - 1.1G 2020-04-09 
17:59
   copperbowl/ROOT/r360237f                     R      - 80.9G 
2020-05-03 18:30
   copperbowl/ROOT/r360237f_at_2020-05-03-18:30:25 -      - 440.0K 
2020-05-03 18:30
root_at_momh167-gjp4-8570p:~ # bectl list -as
BE/Dataset/Snapshot                              Active Mountpoint Space 
Created

Waterfox
   copperbowl/ROOT/Waterfox                       -      - 314M  
2020-03-10 18:24

r357746h
   copperbowl/ROOT/r357746h                       -      - 3.44M 
2020-04-08 09:28

r360237e
   copperbowl/ROOT/r360237e                       N      / 764K  
2020-05-01 17:58

r360237f
   copperbowl/ROOT/r360237f                       R      - 80.9G 
2020-05-03 18:30
   r360237f_at_2020-03-20-06:19:45                   -      - 1.02G 
2020-03-20 06:19
   r360237f_at_2020-04-09-17:59:32                   -      - 1.15G 
2020-04-09 17:59
   r360237f_at_2020-05-03-18:30:25                   -      - 440K  
2020-05-03 18:30
root_at_momh167-gjp4-8570p:~ #
Received on Sun May 03 2020 - 15:44:53 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:41:23 UTC