Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 3 May 2020 18:44:48 +0100
From:      Graham Perrin <grahamperrin@gmail.com>
To:        freebsd-current@freebsd.org
Subject:   Re: beadm no longer able to destroy, maybe since using OpenZFS
Message-ID:  <7bd898ec-7e56-959d-48a5-6cfea4561602@gmail.com>
In-Reply-To: <8e30bce4-e740-2d8b-24dd-b73471bf0fab@gmail.com>
References:  <f8866d18-de55-715a-be31-71ac44dea7dc@gmail.com> <8e30bce4-e740-2d8b-24dd-b73471bf0fab@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
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@momh167-gjp4-8570p:~ # kldstat | grep zfs
>  2    1 0xffffffff82109000   3a8b40 zfs.ko
> root@momh167-gjp4-8570p:~ # date
> Sun May  3 05:59:06 BST 2020

…

> root@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@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@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@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@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@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@2020-05-03-18:30:25               -      - 440.0K 
2020-05-03 18:30

r360237f
   copperbowl/ROOT/r360237f@2020-03-20-06:19:45 -      - 1.0G 2020-03-20 
06:19
   copperbowl/ROOT/r360237f@2020-04-09-17:59:32 -      - 1.1G 2020-04-09 
17:59
   copperbowl/ROOT/r360237f@2020-04-29-13:24:52 -      - 229.0M 
2020-04-29 13:24
   copperbowl/ROOT/r360237f@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@2020-05-03-18:30:25 -      - 440.0K 
2020-05-03 18:30
root@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@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@momh167-gjp4-8570p:~ # kldstat | grep zfs
  2    1 0xffffffff82109000   3a8b40 zfs.ko
root@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@momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f@2020-03-20-06:19:45
cannot destroy 'copperbowl/ROOT/r360237f@2020-03-20-06:19:45': snapshot 
has dependent clones
use '-R' to destroy the following datasets:
copperbowl/ROOT/Waterfox
root@momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f@2020-04-09-17:59:32
cannot destroy 'copperbowl/ROOT/r360237f@2020-04-09-17:59:32': snapshot 
has dependent clones
use '-R' to destroy the following datasets:
copperbowl/ROOT/r357746h
root@momh167-gjp4-8570p:~ # zfs destroy 
copperbowl/ROOT/r360237f@2020-05-01-17:58:33
root@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@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@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@2020-05-03-18:30:25               -      - 440.0K 
2020-05-03 18:30

r360237f
   copperbowl/ROOT/r360237f@2020-03-20-06:19:45 -      - 1.0G 2020-03-20 
06:19
   copperbowl/ROOT/r360237f@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@2020-05-03-18:30:25 -      - 440.0K 
2020-05-03 18:30
root@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@2020-03-20-06:19:45                   -      - 1.02G 
2020-03-20 06:19
   r360237f@2020-04-09-17:59:32                   -      - 1.15G 
2020-04-09 17:59
   r360237f@2020-05-03-18:30:25                   -      - 440K  
2020-05-03 18:30
root@momh167-gjp4-8570p:~ #




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?7bd898ec-7e56-959d-48a5-6cfea4561602>