Documented wwctl clean

Closes #2034

Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
Jonathon Anderson
2026-03-18 14:22:49 -06:00
parent c13c94ff85
commit db7e859112
4 changed files with 75 additions and 5 deletions

View File

@@ -12,6 +12,8 @@ functionality.
to multiple nodes
* ``image``: configures (node) images
* ``overlays``: manages overlays
* ``clean``: removes the OCI image cache and leftover overlay images from
deleted nodes
``wwctl`` also provides additional helpers for interacting with cluster nodes
over SSH and IPMI.
@@ -56,3 +58,29 @@ For each node, there are 4 different stages:
You can use the ``wwctl node status`` to check communication between the
Warewulf server (``warewulfd``) and the Warewulf client (``wwclient``).
Maintenance
===========
``wwctl clean`` reclaims disk space by removing two categories of data that
accumulate over time:
* The OCI blob cache, stored at ``$cachedir/warewulf`` (default:
``/var/cache/warewulf``). This cache is populated during ``wwctl image
import`` and speeds up subsequent imports of images that share layers. It
is safe to remove: the next ``wwctl image import`` will re-download any
needed layers.
* Provisioned overlay images for nodes that have been deleted from the node
database. These are stored under ``$wwprovisiondir/overlays`` and are no
longer needed once the corresponding node is removed.
.. code-block:: console
# wwctl clean
``wwctl clean`` is particularly useful after deleting a large number of nodes,
or when disk space is limited on the Warewulf server. Note that ``wwctl clean``
only removes the current cache location (``$cachedir/warewulf``); if you are
upgrading from v4.5.x, the legacy cache at ``$datastore/oci`` must be removed
manually (see :ref:`oci-blob-cache`).