From b77ae7eb8523da696fcb0f48a747ac22bdc9eb31 Mon Sep 17 00:00:00 2001 From: Jo Zzsi Date: Sat, 1 Nov 2025 19:20:42 -0400 Subject: [PATCH] feat: rename rd.live.overlay.overlayfs to rd.overlayfs The overlayfs dracut module can be used without the dmsquash-live dracut module. This change improves on naming of command line options with better namespace scoping. Move overlayfs documentation out of the live images section. Follow-up to 40dd5c90e. --- man/dracut.cmdline.7.adoc | 53 ++++++++++--------- .../70dmsquash-live/dmsquash-generator.sh | 4 +- .../70dmsquash-live/dmsquash-live-root.sh | 6 +-- modules.d/70livenet/livenet-generator.sh | 4 +- modules.d/70overlayfs/mount-overlayfs.sh | 4 +- modules.d/70overlayfs/prepare-overlayfs.sh | 2 +- test/TEST-30-DMSQUASH/test.sh | 2 +- test/TEST-60-NFS/test.sh | 4 +- 8 files changed, 42 insertions(+), 37 deletions(-) diff --git a/man/dracut.cmdline.7.adoc b/man/dracut.cmdline.7.adoc index 6e54be4ce..272608151 100644 --- a/man/dracut.cmdline.7.adoc +++ b/man/dracut.cmdline.7.adoc @@ -1086,6 +1086,29 @@ rd.znet=qeth,0.0.0600,0.0.0601,0.0.0602,layer2=1,portname=foo rd.znet=ctc,0.0.0600,0.0.0601,protocol=bar -- +OverlayFS +~~~~~~~~~ +Requires the dracut 'overlayfs' module. + +**rd.overlayfs=**1:: +Enables the use of the *OverlayFS* kernel module, if available, to provide a +copy-on-write union directory for the root filesystem. OverlayFS overlays are +directories of the files that have changed on the read-only base (lower) +filesystem. The root filesystem is provided through a special overlay type +mount that merges at least two directories, designated the lower and the upper. +If an OverlayFS upper directory is not present on the boot device, a tmpfs +directory will be created at `/run/overlayfs` to provide temporary storage. +Persistent storage can be provided on vfat or msdos formatted devices by +supplying the OverlayFS upper directory within an embedded filesystem that +supports the creation of trusted.* extended attributes and provides a valid +d_type in readdir responses, such as with btrfs, ext4, f2fs, & xfs. On +non-vfat-formatted devices, a persistent OverlayFS overlay can extend the +available root filesystem storage up to the capacity of the LiveOS disk device. ++ +The **rd.overlayfs.readonly** option, which allows a persistent overlayfs to +be mounted read-only through a higher level transient overlay directory, has +been implemented through the multiple lower layers feature of OverlayFS. + Booting live images ~~~~~~~~~~~~~~~~~~~ Requires the dracut 'dmsquash-live' module. @@ -1129,7 +1152,7 @@ filesystem, which often provide only a small number of gigabytes of free space. This shortage could be remedied by building the root filesystem with more allocated free space, or the OverlayFS based overlay mount method can be used. -When the *_rd.live.overlay.overlayfs_* option is specified or when +When the *_rd.overlayfs_* option is specified or when *_rd.live.overlay=_* points to an appropriate directory with a sister at `/../ovlwork`, then an OverlayFS based overlay mount is employed. Such a persistent OverlayFS overlay can extend the available root filesystem storage @@ -1293,7 +1316,7 @@ where _