[OpenIndiana-discuss] safely cleanup pkg cache?

Tim Mooney Tim.Mooney at ndsu.edu
Mon Feb 22 23:13:54 UTC 2021


In regard to: Re: [OpenIndiana-discuss] safely cleanup pkg cache?, Andreas...:

> Am 21.02.21 um 22:42 schrieb Stephan Althaus:
>> Hello!
>> 
>> The "-s" option does the minimal obvious remove of the corresponding
>> snapshot:

My experience seems to match what Andreas and Toomas are saying: -s isn't
doing what it's supposed to be doing (?).

After using

 	sudo beadm destroy -F -s -v <bename>

to destroy a dozen or so boot environments, I'm down to just this
for boot environments:

$ beadm list
BE                                Active Mountpoint Space  Policy Created
openindiana                       -      -          12.05M static 2019-05-17 10:37
openindiana-2021:02:07            -      -          27.27M static 2021-02-07 01:01
openindiana-2021:02:07-backup-1   -      -          117K   static 2021-02-07 13:06
openindiana-2021:02:07-backup-2   -      -          117K   static 2021-02-07 13:08
openindiana-2021:02:07-1          NR     /          51.90G static 2021-02-07 17:23
openindiana-2021:02:07-1-backup-1 -      -          186K   static 2021-02-07 17:48
openindiana-2021:02:07-1-backup-2 -      -          665K   static 2021-02-07 17:58
openindiana-2021:02:07-1-backup-3 -      -          666K   static 2021-02-07 18:02


However, zfs list still shows (I think) snapshots for some of the
intermediate boot environments that I destroyed:

$ zfs list -t snapshot
NAME                                                      USED  AVAIL  REFER  MOUNTPOINT
rpool/ROOT/openindiana-2021:02:07-1 at install               559M      -  5.94G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-05-17-18:34:55   472M      -  6.28G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-05-17-18:46:32   555K      -  6.28G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-05-17-18:48:56  2.18M      -  6.45G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-06-13-22:13:18  1015M      -  9.74G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-06-21-16:25:04  1.21G      -  9.85G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-08-23-16:17:28   833M      -  9.74G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-08-28-21:51:55  1.40G      -  10.8G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-09-12-23:35:08   643M      -  11.7G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-10-02-22:55:57   660M      -  12.0G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-11-09-00:04:17   736M      -  12.4G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-12-05-01:02:10  1.02G      -  12.7G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2019-12-20-19:55:51   788M      -  12.9G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2020-02-13-23:17:35   918M      -  13.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-01-21-02:27:31  1.74G      -  13.9G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-06-22:47:15  1.71G      -  18.8G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-06:59:02  1.22G      -  19.1G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-19:06:07   280M      -  19.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-19:08:29   280M      -  19.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-23:21:52   640K      -  19.1G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-23:23:46   868K      -  19.2G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-23:48:07   294M      -  19.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-07-23:58:44   280M      -  19.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-08-00:02:17   280M      -  19.3G  -
rpool/ROOT/openindiana-2021:02:07-1 at 2021-02-21-06:24:56  3.49M      -  19.4G  -

Now I have to figure out how to map the zfs snapshots to the boot
environments that I kept, so that I can "weed out" the zfs snapshots
that I don't need.

I appreciate all the discussion and info my question has spawned!  I
didn't anticipate the issue being as complicated as it appears it is.

Tim
-- 
Tim Mooney                                             Tim.Mooney at ndsu.edu
Enterprise Computing & Infrastructure /
Division of Information Technology    /                701-231-1076 (Voice)
North Dakota State University, Fargo, ND 58105-5164



More information about the openindiana-discuss mailing list