From b1198e1698fe6c69a09c85a162bb61fc43c6dd4d Mon Sep 17 00:00:00 2001 From: Stephan Raue Date: Sun, 4 Aug 2013 14:33:02 +0200 Subject: [PATCH] busybox-initramfs: enable systemd as default init system Signed-off-by: Stephan Raue --- .../initramfs/sysutils/busybox-initramfs/scripts/init | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/initramfs/sysutils/busybox-initramfs/scripts/init b/packages/initramfs/sysutils/busybox-initramfs/scripts/init index 04104c6f09..6c08bbbf80 100755 --- a/packages/initramfs/sysutils/busybox-initramfs/scripts/init +++ b/packages/initramfs/sysutils/busybox-initramfs/scripts/init @@ -76,8 +76,12 @@ disk=*) disk="${arg#*=}" ;; + installer) + INIT_ARGS="$INIT_ARGS --unit=installer.target" + ;; debugging) DEBUG=yes + INIT_ARGS="$INIT_ARGS --log-level=debug" ;; bootchart) BOOTCHART=yes @@ -87,6 +91,7 @@ ;; progress) PROGRESS=yes + INIT_ARGS="$INIT_ARGS --show-status=1" ;; nosplash) SPLASH=no @@ -538,7 +543,7 @@ mount --move /storage /sysroot/storage fi - [ -f "/sysroot/sbin/init" ] || error "final_check" "Could not find system." + [ -f "/sysroot/lib/systemd/systemd" ] || error "final_check" "Could not find system." } if [ "${boot%%=*}" = "FILE" ]; then @@ -565,6 +570,6 @@ /bin/busybox mount --move /sys /sysroot/sys # switch to new sysroot and start real init - exec /bin/busybox switch_root /sysroot /sbin/init + exec /bin/busybox switch_root /sysroot /lib/systemd/systemd $INIT_ARGS error "switch_root" "Error in initramfs. Could not switch to new root"