aboutsummaryrefslogtreecommitdiff
path: root/initramfs_init
diff options
context:
space:
mode:
authorArslaan Pathan <[email protected]>2026-06-08 19:59:29 +1200
committerArslaan Pathan <[email protected]>2026-06-08 19:59:29 +1200
commit93f35914637f53007f4fddb4d64069612c7b2b2f (patch)
tree5bb92695711b46eb919852f3a3458bf9ea76a1d2 /initramfs_init
parent18ee85b9efe6ab31db652e9a9f919603ca5edd4b (diff)
downloadyerbalinux-93f35914637f53007f4fddb4d64069612c7b2b2f.tar.xz
yerbalinux-93f35914637f53007f4fddb4d64069612c7b2b2f.zip
Fix init issue and work on making graphical tty show
Diffstat (limited to 'initramfs_init')
-rw-r--r--initramfs_init13
1 files changed, 12 insertions, 1 deletions
diff --git a/initramfs_init b/initramfs_init
index ef327ce..b1aface 100644
--- a/initramfs_init
+++ b/initramfs_init
@@ -35,8 +35,19 @@ echo "[yerba-initramfs/init] Mounted tmpfs at /mnt/overlay and created upper, wo
mount -t overlay overlay -o lowerdir=/mnt/root,upperdir=/mnt/overlay/upper,workdir=/mnt/overlay/work /mnt/overlay/merged
echo "[yerba-initramfs/init] Mounted OverlayFS at /mnt/overlay/merged"
+if [ ! -c /dev/console ]; then
+ echo "[yerba-initramfs/init] console device not found, creating"
+ mknod -m 600 /dev/console c 5 1
+fi
+
+
+if [ ! -c /dev/tty0 ]; then
+ echo "[yerba-initramfs/init] tty0 device not found, creating"
+ mknod -m 620 /dev/tty0 c 4 0
+fi
+
echo "[yerba-initramfs/init] Switching to overlay root..."
-exec switch_root /mnt/overlay/merged /sbin/init
+exec switch_root /mnt/overlay/merged /init
echo "[yerba-initramfs/init] switch_root failed, dropping to shell"
exec /bin/sh