From: Daniel Hokka Zakrisson Date: Mon, 26 Feb 2007 20:18:03 +0000 (+0000) Subject: Make the gentoo initstyle work with baselayout-vserver. X-Git-Tag: release-0.30.214~96 X-Git-Url: http://git.linux-vserver.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4434ece05f02e6f5bebd6854172e1de056b405c2;p=util-vserver.git Make the gentoo initstyle work with baselayout-vserver. git-svn-id: http://svn.linux-vserver.org/svn/util-vserver/trunk@2509 94cd875c-1c1d-0410-91d2-eb244daf1a30 --- diff --git a/distrib/gentoo/init-vserver.sh b/distrib/gentoo/init-vserver.sh index 12fcda9..e628d9f 100644 --- a/distrib/gentoo/init-vserver.sh +++ b/distrib/gentoo/init-vserver.sh @@ -24,6 +24,7 @@ # You have been warned... # -RUNLEVEL=1 /sbin/rc sysinit -/sbin/rc boot +RUNLEVEL=1 /sbin/rc sysinit || exit 1 +/sbin/rc boot || exit 1 /sbin/rc ${1:-default} +exit 0 diff --git a/scripts/vserver.functions b/scripts/vserver.functions index c9d9a47..7ddeb47 100644 --- a/scripts/vserver.functions +++ b/scripts/vserver.functions @@ -306,21 +306,6 @@ function _generateInitOptions INITCMD_START=( /lib/rcscripts/sh/init-vserver.sh "$RUNLEVEL_START" ) INITCMD_STOP=( /sbin/rc shutdown ) INITCMD_PREPARE=( $_FAKE_RUNLEVEL 3 /var/run/utmp ) - - pushd "$vdir"/vdir &>/dev/null - basever=$($_CHROOT_SH cat /etc/gentoo-release | $_AWK '{print $5}') - popd &>/dev/null - - basemaj=${basever/.*} - basemin=${basever#*.} - basemin=${basemin/.*} - - test "$basemaj" -lt 1 -o "$basemin" -lt 13 && \ - panic "\ -Using init-style 'gentoo' requires >=baselayout-1.13 inside the vserver! - -Your vserver ($(basename "$vdir")) seems to have baselayout-$basever, -please use 'plain' init-style instead!" ;; (x) ;;