Skip to contentSkip to conversation

sysvinit-inittab: start runlevel 5 after terminals

PATCH New Joe Slater 1 participant 1 message May 8, 2013

lore
Share & tools
lore

Joe Slater

author
#0 lore raw

PATCH 1/1 sysvinit-inittab: start runlevel 5 after terminals

If xserver is started before getty is attached to virtual terminals, the server might lose the ability to accept keyboard input, so we go to runlevel 5 at the very end of inittab.

---
 .../recipes-core/sysvinit/sysvinit-inittab/inittab |    4 +++-
 .../sysvinit/sysvinit-inittab_2.88dsf.bb           |    6 +++++-
 2 files changed, 8 insertions(+), 2 deletions(-)
meta/recipes-core/sysvinit/sysvinit-inittab/inittab +3 -1
index 6abbdf4..519ae17 100644
@@ -24,7 +24,9 @@ l1:1:wait:/etc/init.d/rc 1
 l2:2:wait:/etc/init.d/rc 2
 l3:3:wait:/etc/init.d/rc 3
 l4:4:wait:/etc/init.d/rc 4
-l5:5:wait:/etc/init.d/rc 5
+#
+# go into runlevel 5 ONLY after starting getty's
+#
 l6:6:wait:/etc/init.d/rc 6
 # Normally not reached, but fallthrough in case of emergency.
 z6:6:respawn:/sbin/sulogin
meta/recipes-core/sysvinit/sysvinit-inittab_2.88dsf.bb +5 -1
index 23c284d..d4cb6b9 100644
@@ -2,7 +2,7 @@ DESCRIPTION = "Inittab for sysvinit"
 LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
 
-PR = "r9"
+PR = "r10"
 
 SRC_URI = "file://inittab"
 
@@ -45,6 +45,10 @@ EOF
         done
         echo "" >> ${D}${sysconfdir}/inittab
     fi
+
+    # Going to runlevel 5 should be the last thing in inittab.
+    #
+    echo "l5:5:wait:/etc/init.d/rc 5" >> ${D}${sysconfdir}/inittab
 }
 
 pkg_postinst_${PN} () {
Signature · 1 line
1.7.3.4