commit: bd2f2e1ea079d1721d8fcf684c966d556b763d3e Author: Ben Kohler <bkohler <AT> gentoo <DOT> org> AuthorDate: Fri Feb 16 19:38:28 2024 +0000 Commit: Ben Kohler <bkohler <AT> gentoo <DOT> org> CommitDate: Fri Feb 16 19:38:28 2024 +0000 URL: https://gitweb.gentoo.org/proj/genkernel.git/commit/?id=bd2f2e1e
initrd.scripts: create dir layout for overlayfs as well These dirs like /mnt/gentoo are normally created during boot but overlayfs usage bypasses that. Let's create them for overlayfs users as well. Signed-off-by: Ben Kohler <bkohler <AT> gentoo.org> defaults/initrd.scripts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts index 01bfe07..506f8c6 100644 --- a/defaults/initrd.scripts +++ b/defaults/initrd.scripts @@ -855,6 +855,13 @@ setup_overlayfs() { run mount --bind "${i}" "${NEW_ROOT}${i}" done + # Setup the filesystem nodes and directories + # Copied from non-overlayfs logic earlier in this script + for i in ${CDROOT_PATH} /mnt/header /mnt/livecd /mnt/key /mnt/gentoo /tmp /tmp/.initrd /dev /proc /run /sys; do + run mkdir -p "${NEW_ROOT}${i}" + run chmod 755 "${NEW_ROOT}${i}" + done + # Did we populate the overlayfs modules path locations variable? if [ -n "${mods}" ] then