Skip to content

Commit df36cdf

Browse files
committed
Update v4.6.x docs
1 parent 6b710bc commit df36cdf

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+862
-110
lines changed

static/docs/v4.6.x/_sources/getting-started/debian-quickstart.rst.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ and set it for the "default" node profile.
127127

128128
.. code-block:: bash
129129
130-
sudo wwctl image import docker://ghcr.io/warewulf/warewulf-debian:12.0 debian-12.0
130+
sudo wwctl image import --build docker://ghcr.io/warewulf/warewulf-debian:12.0 debian-12.0
131131
sudo wwctl profile set default --image=debian-12.0
132132
133133
Set up the default node profile
@@ -179,7 +179,7 @@ configurations.
179179

180180
.. code-block:: bash
181181
182-
sudo wwctl node add n0000.cluster --ipaddr 192.168.200.100 --discoverable true
182+
sudo wwctl node add n0000.cluster --ipaddr 192.168.200.100 --discoverable
183183
184184
At this point you can view the basic configuration of this node by
185185
typing the following:

static/docs/v4.6.x/_sources/nodes/disks.rst.txt

Lines changed: 116 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,8 @@ Provisioning disks
44

55
As a tech preview, Warewulf provides structures to define disks, partitions, and
66
file systems. These structures can generate a configuration for `Ignition`_ to
7-
provision partitions and file systems dynamically on cluster nodes.
7+
provision partitions and file systems dynamically on cluster nodes, or with
8+
sfdisk, mkfs, and mkswap during boot.
89

910
.. _Ignition: https://coreos.github.io/ignition/
1011

@@ -145,3 +146,117 @@ file systems once, you may
145146
See the `upstream ignition documentation`_ for additional information.
146147

147148
.. _upstream ignition documentation: https://coreos.github.io/ignition/operator-notes/#filesystem-reuse-semantics
149+
150+
151+
.. _provision to disk:
152+
153+
Provision to disk
154+
=================
155+
156+
*New in Warewulf v4.6.2*
157+
158+
As a tech preview, the Warewulf two-stage boot process can provision the node
159+
image to local storage.
160+
161+
.. warning::
162+
163+
This functionality is a technology preview and should be used with care. Pay
164+
specific attention to ``wipeFilesytem`` and similar settings.
165+
166+
.. note::
167+
168+
Warewulf doesn't install a bootloader to the disk or add UEFI entries. Nodes
169+
still request an image and configuration from the Warewulf server on every
170+
boot.
171+
172+
.. note::
173+
174+
While provisioning to disk should be possible during a single-stage boot, not
175+
all features are available:
176+
177+
- Warewulf does not perform hardware detection to ensure that necessary
178+
kernel modules are loaded prior to init.
179+
- Warewulf does not load udev to ensure that ``/dev/disk/by-*`` symlinks are
180+
available prior to init.
181+
182+
With Ignition
183+
-------------
184+
185+
Warewulf needs a prepared file system to deploy the image to. Warewulf can
186+
provision this file system using Ignition. To use Ignition, include ``ignition``
187+
in your system overlay. The ignition overlay provisions disks during init and,
188+
optionally, during the first stage of a two-stage boot. This allows the
189+
root file system to be provisioned before the image is loaded.
190+
191+
.. code-block:: shell
192+
193+
wwctl node set wwnode1 \
194+
--diskname /dev/vda --diskwipe \
195+
--partname rootfs --partcreate --partnumber 1 \
196+
--fsname rootfs --fsformat ext4 --fspath /
197+
198+
In order to allow Dracut to provision the disk, partition, and file system,
199+
Ignition must be included in the Dracut image.
200+
201+
.. code-block:: shell
202+
203+
wwctl image exec rockylinux-9 -- /usr/bin/dracut --force --no-hostonly --add wwinit --add ignition --regenerate-all
204+
205+
The necessary file system may alternatively be prepared out-of-band.
206+
207+
With sfdisk and mkfs
208+
--------------------
209+
210+
Systems that do not have access to Ignition (e.g., Rocky Linux 8) can provision
211+
the root file system using a combination of ``sfdisk`` and ``mkfs``. To use
212+
them, include ``sfdisk`` and ``mkfs`` in your system overlay. The ``sfdisk`` and
213+
``mkfs`` overlays provision disk and file systems during the first stage of a
214+
two-stage boot. This allows the root file system to be provisioned before the
215+
image is loaded.
216+
217+
Configure the ``sfdisk`` and ``mkfs`` overlays using resources:
218+
219+
.. code-block:: shell
220+
221+
wwctl node set wwnode1 \
222+
--diskname /dev/vda --diskwipe \
223+
--partname rootfs --partcreate --partnumber 1 \
224+
--fsname rootfs --fsformat ext4 --fspath /
225+
226+
In order to allow Dracut to provision the disk, partition, and file system, some
227+
additional commands must be included in the Dracut image, depending on which
228+
functionality is used:
229+
230+
- **sfdisk:** writes the partition table
231+
232+
- **blockdev:** used to re-read the partition table after writing
233+
234+
- **udevadm:** used to trigger udev events after writing the partition table
235+
236+
- **mkfs:** formats file systems (may also require file-system-specific commands like mkfs.ext4)
237+
238+
- **mkfs.ext4**, **mkfs.btrfs**, etc: used by mkfs to format specific file systems
239+
240+
- **wipefs:** used to determine if a file system already exists
241+
242+
.. code-block:: shell
243+
244+
wwctl image exec rockylinux-8 -- /usr/bin/dracut --force --no-hostonly \
245+
--add wwinit \
246+
--install sfdisk \
247+
--install blockdev \
248+
--install udevadm \
249+
--install mkfs \
250+
--install mkfs.ext4 \
251+
--install wipefs \
252+
--regenerate-all
253+
254+
Configuring the root device
255+
---------------------------
256+
257+
Set the desired storage device for the node image using the ``--root``
258+
parameter.
259+
260+
.. code-block:: shell
261+
262+
wwctl node set wwnode1 --root /dev/disk/by-partlabel/rootfs

static/docs/v4.6.x/_sources/nodes/network.rst.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,17 @@ specifying ``--netname``.
3434
an interface may fail to be named correct if its desired name conflicts with
3535
the kernel-assigned name of another interface during the boot process.
3636

37+
.. _nettags:
38+
39+
Network Tags
40+
============
41+
42+
Each network device can optionally have one or more key-value pair tags.
43+
44+
.. code-block:: shell
45+
46+
wwctl node set n1 --nettagadd="DNS1=1.1.1.1"
47+
3748
.. _bonding:
3849

3950
Bonding

static/docs/v4.6.x/_sources/nodes/nodes.rst.txt

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -199,3 +199,48 @@ overlays.
199199
passno: 0
200200
201201
Resources can only be managed with ``wwctl node edit``.
202+
203+
Importing Nodes From a File
204+
===========================
205+
206+
You can import nodes into Warewulf by using the ``wwctl node import`` command.
207+
The file used must be in YAML format.
208+
209+
The YAML file must be a mapping of node names to their attributes, where each
210+
node is represented as a dictionary of attributes. To simplify the creation of
211+
the YAML file, you can use the wwctl node export command to export the current
212+
node configuration to a YAML file. This exported file can serve as a template
213+
for creating new nodes.
214+
215+
A minimal example of a YAML file looks like this:
216+
217+
.. code-block:: yaml
218+
219+
n1:
220+
profiles:
221+
- default
222+
image name: rockylinux-9
223+
ipxe template: default
224+
kernel:
225+
args:
226+
- quiet
227+
- crashkernel=no
228+
- nosplash
229+
- console=ttyS0,115200
230+
network devices:
231+
default:
232+
type: ethernet
233+
device: eno1
234+
hwaddr: "00:00:00:00:00:01"
235+
ipaddr: 10.0.2.1
236+
netmask: 255.255.255.0
237+
gateway: 172.16.131.1
238+
tags:
239+
DNS1: 1.1.1.1
240+
primary network: default
241+
242+
This can be imported with the following command:
243+
244+
.. code-block:: shell
245+
246+
wwctl node import /path/to/nodes.yaml

0 commit comments

Comments
 (0)