Colleagues, tell me, please, how can I remove unnecessary snapshots without error?
Apparently, every time, with a binary update of the operating system, a snapshot was put on zroot.
Apparently, these snapshots take up a lot of space, and besides, there is no need for them - the binary updates went well and there was no need to return to the previous points.
I tried deleting these snapshots, but I don't want the current contents of zroot to change. It suits me just fine.
Let me remind you once again that I don’t need these snapshots and I just want to get rid of them without affecting the current state of the file system.
I don't really understand what dataset means in this context, and I'm unsure of my actions.
If I use the -R option, will I be able to complete this task? It is very important for me not to get problems with the current zroot content. It must not change its current value!
Grateful for the answer,
Ogogon.
Apparently, every time, with a binary update of the operating system, a snapshot was put on zroot.
Code:
ogogon@server:/tmp# zfs list
NAME USED AVAIL REFER MOUNTPOINT
zroot 899G 38,3M 88K /zroot
zroot/ROOT 899G 38,3M 88K none
zroot/ROOT/12.3-RELEASE-p1_2022-05-02_184810 8K 38,3M 893G /
zroot/ROOT/12.3-RELEASE_2022-01-13_095203 8K 38,3M 894G /
zroot/ROOT/default 899G 38,3M 736G /
zroot/tmp 9,19M 38,3M 9,19M /tmp
zroot/usr 264K 38,3M 88K /usr
zroot/usr/home 88K 38,3M 88K /usr/home
zroot/usr/src 88K 38,3M 88K /usr/src
zroot/var 21,3M 38,3M 88K /var
zroot/var/audit 88K 38,3M 88K /var/audit
zroot/var/crash 88K 38,3M 88K /var/crash
zroot/var/log 8,55M 38,3M 8,55M /var/log
zroot/var/mail 120K 38,3M 120K /var/mail
zroot/var/tmp 12,4M 38,3M 12,4M /var/tmp
ogogon@server:/tmp# zfs list -t snapshot
NAME USED AVAIL REFER MOUNTPOINT
zroot/ROOT/default@2022-01-13-09:52:03-0 2,49G - 894G -
zroot/ROOT/default@2022-05-02-18:48:10-0 1,22G - 893G -
ogogon@server:/tmp#
Apparently, these snapshots take up a lot of space, and besides, there is no need for them - the binary updates went well and there was no need to return to the previous points.
I tried deleting these snapshots, but I don't want the current contents of zroot to change. It suits me just fine.
Code:
ogogon@server:/tmp# zfs destroy zroot/ROOT/default@2022-05-02-18:48:10-0
cannot destroy 'zroot/ROOT/default@2022-05-02-18:48:10-0': snapshot has dependent clones
use '-R' to destroy the following datasets:
zroot/ROOT/12.3-RELEASE-p1_2022-05-02_184810
ogogon@server:/tmp#
Let me remind you once again that I don’t need these snapshots and I just want to get rid of them without affecting the current state of the file system.
I don't really understand what dataset means in this context, and I'm unsure of my actions.
If I use the -R option, will I be able to complete this task? It is very important for me not to get problems with the current zroot content. It must not change its current value!
Grateful for the answer,
Ogogon.