🇩🇪 Deutsch

05 Nov 2024

FreeBSD: Boot-Environment aufräumen

Interessanterweise cann man einiges an Platz bei einem FreeBSD-System sparen, in dem man alte Boot-Environments löscht, welche nach mehreren FreeBSD-Updates schon einges an Platz beanspruchen können.

auf dem Server fuchsia

  • Vorhandene, alte Boot-Environments ansehen
[root@fuchsia #]$ uname -a
FreeBSD fuchsia 14.1-RELEASE-p5 FreeBSD 14.1-RELEASE-p5 GENERIC amd64

[root@fuchsia]# bectl list
BE                                 Active Mountpoint Space Created
14.0-RELEASE-p10_2024-09-11_074137 -      -          46.2M 2024-09-11 07:41
14.0-RELEASE-p11_2024-11-01_205323 -      -          70.4M 2024-11-01 20:53
14.0-RELEASE-p11_2024-11-05_125604 -      -          57.6M 2024-11-05 12:56
14.0-RELEASE-p4_2024-03-03_152009  -      -          100G  2024-03-03 15:20
14.0-RELEASE-p5_2024-04-25_071739  -      -          7.10G 2024-04-25 07:17
14.0-RELEASE-p6_2024-07-09_152214  -      -          6.27G 2024-07-09 15:22
14.0-RELEASE-p8_2024-09-11_072822  -      -          47.2M 2024-09-11 07:28
14.0-RELEASE_2024-01-20_173821     -      -          439M  2024-01-20 17:38
14.1-RELEASE-p4_2024-11-01_174027  -      -          24.8M 2024-11-01 17:40
14.1-RELEASE-p4_2024-11-01_183855  -      -          406M  2024-11-01 18:38
14.1-RELEASE-p5_2024-11-05_120355  -      -          101M  2024-11-05 12:03
14.1-RELEASE-p5_2024-11-06_073142  -      -          50.7M 2024-11-06 07:31
14.1-RELEASE-p6_2024-11-05_123738  -      -          431M  2024-11-05 12:37
14.1-RELEASE-p6_2024-11-06_074835  -      -          43.4M 2024-11-06 07:48
default                            NR     /          516G  2024-01-20 12:29
  • nicht benötigte Boot-Environments löschen
    • Hierbei gilt es natürlich, Vorsicht walten zu lassen!
[root@fuchsia]# bectl destroy 14.0-RELEASE-p4_2024-03-03_152009
...
  • Es konnte einiges an Gigabytes eingespart werden - YMMV
[root@fuchsia]# bectl list
BE                                 Active Mountpoint Space Created
14.0-RELEASE-p11_2024-11-05_125604 -      -          57.6M 2024-11-05 12:56
14.1-RELEASE-p4_2024-11-01_174027  -      -          1.51G 2024-11-01 17:40
14.1-RELEASE-p5_2024-11-06_073142  -      -          50.7M 2024-11-06 07:31
14.1-RELEASE-p6_2024-11-05_123738  -      -          504M  2024-11-05 12:37
14.1-RELEASE-p6_2024-11-06_074835  -      -          45.1M 2024-11-06 07:48
default                            NR     /          343G  2024-01-20 12:29

auf dem Server gliese1

root@gliese1:# uname -a
FreeBSD gliese1 13.4-RELEASE-p1 FreeBSD 13.4-RELEASE-p1 GENERIC amd64

root@gliese1:# bectl list
BE                                 Active Mountpoint Space Created
12.3-RELEASE-p10_2022-12-08_144931 -      -          15.1M 2022-12-08 14:49
12.3-RELEASE-p4_2022-12-07_172113  -      -          831M  2022-12-07 17:21
13.1-RELEASE-p3_2022-12-08_150736  -      -          7.77M 2022-12-08 15:07
13.1-RELEASE-p5_2022-12-08_152330  -      -          30.5M 2022-12-08 15:23
13.1-RELEASE-p5_2023-04-20_133553  -      -          282M  2023-04-20 13:35
13.1-RELEASE-p7_2023-04-24_103301  -      -          190M  2023-04-24 10:33
13.1-RELEASE-p7_2024-01-14_120325  -      -          38.9M 2024-01-14 12:03
13.1-RELEASE-p9_2024-01-14_125348  -      -          14.0M 2024-01-14 12:53
13.2-RELEASE-p10_2024-03-15_115334 -      -          10.7M 2024-03-15 11:53
13.2-RELEASE-p8_2024-01-14_125916  -      -          11.5M 2024-01-14 12:59
13.2-RELEASE-p9_2024-03-15_085002  -      -          105M  2024-03-15 08:50
13.3-RELEASE-p2_2024-07-09_154408  -      -          476M  2024-07-09 15:44
13.3-RELEASE-p4_2024-11-08_134953  -      -          145M  2024-11-08 13:49
13.3-RELEASE-p8_2024-11-09_104111  -      -          5.54M 2024-11-09 10:41
13.3-RELEASE_2024-03-15_121320     -      -          16.4M 2024-03-15 12:13
13.3-RELEASE_2024-06-19_102008     -      -          1.05G 2024-06-19 10:20
13.4-RELEASE-p1_2024-11-09_104559  -      -          5.11M 2024-11-09 10:46
default                            NR     /          329G  2018-11-24 12:56

root@gliese1:# bectl destroy 12.3-RELEASE-p4_2022-12-07_172113
root@gliese1:# bectl destroy 12.3-RELEASE-p10_2022-12-08_144931
root@gliese1:# bectl destroy 13.1-RELEASE-p3_2022-12-08_150736
root@gliese1:# bectl destroy 13.1-RELEASE-p5_2022-12-08_152330
root@gliese1:# bectl destroy 13.1-RELEASE-p5_2023-04-20_133553
root@gliese1:# bectl destroy 13.1-RELEASE-p7_2023-04-24_103301
root@gliese1:# bectl destroy 13.1-RELEASE-p7_2024-01-14_120325
root@gliese1:# bectl destroy 13.1-RELEASE-p9_2024-01-14_125348
root@gliese1:# bectl destroy 13.2-RELEASE-p10_2024-03-15_115334
root@gliese1:# bectl destroy 13.2-RELEASE-p8_2024-01-14_125916
root@gliese1:# bectl destroy 13.2-RELEASE-p9_2024-03-15_085002
root@gliese1:# bectl destroy 13.3-RELEASE-p2_2024-07-09_154408

root@gliese1:# bectl list
BE                                Active Mountpoint Space Created
13.3-RELEASE-p2_2024-07-09_154408 -      -          1.93G 2024-07-09 15:44
13.3-RELEASE-p4_2024-11-08_134953 -      -          145M  2024-11-08 13:49
13.3-RELEASE-p8_2024-11-09_104111 -      -          5.54M 2024-11-09 10:41
13.3-RELEASE_2024-03-15_121320    -      -          171G  2024-03-15 12:13
13.4-RELEASE-p1_2024-11-09_104559 -      -          5.11M 2024-11-09 10:46
default                           NR     /          202G  2018-11-24 12:56
root@gliese1:# bectl destroy 13.3-RELEASE-p2_2024-07-09_154408
root@gliese1:# bectl destroy 13.3-RELEASE-p4_2024-11-08_134953
root@gliese1:# bectl destroy 13.3-RELEASE-p8_2024-11-09_104111

root@gliese1:# bectl list
BE                                Active Mountpoint Space Created
13.3-RELEASE_2024-03-15_121320    -      -          173G  2024-03-15 12:13
13.4-RELEASE-p1_2024-11-09_104559 -      -          5.89G 2024-11-09 10:46
default                           NR     /          200G  2018-11-24 12:56
root@gliese1:# bectl destroy 13.3-RELEASE_2024-03-15_121320

root@gliese1:# bectl list
BE                                Active Mountpoint Space Created
13.4-RELEASE-p1_2024-11-09_104559 -      -          12.5G 2024-11-09 10:46
default                           NR     /          27.5G 2018-11-24 12:56