+++ /dev/null
-#!/bin/sh
-# chkconfig: 345 98 02
-# description: Wrapper to start the default vservers
-
-. /etc/init.d/functions
-
-[ -n "$UTIL_VSERVER_VARS" ] || UTIL_VSERVER_VARS=/usr/lib/util-vserver/util-vserver-vars
-if [ ! -e "$UTIL_VSERVER_VARS" ] ; then
- echo "Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
- exit 1
-fi
-. "$UTIL_VSERVER_VARS"
-
-[ -n "$MARK" ] || MARK=default
-[ -n "$NUMPARALLEL" ] || NUMPARALLEL=6
-
-_tellResult()
-{
- local rc=$1
- case "$rc" in
- (0) ok;;
- (2) ok; rc=0;;
- (*) fail;;
- esac
- return $rc
-}
-
-case "$1" in
- start)
- if [ ! -f /var/lock/subsys/vservers-$MARK ] ; then
- show "Starting vservers of type '$MARK'"
- busy
- $_START_VSERVERS -m "$MARK" -j "$NUMPARALLEL" --all --start
- _tellResult $?
- RETVAL=$?
- [ $RETVAL -eq 0 ] && touch /var/lock/subsys/vservers-$MARK
- else
- msg_already_running "vservers of type '$MARK'"
- fi
- ;;
- stop)
- if [ -f /var/lock/subsys/vservers-$MARK ] ; then
- show "Stopping vservers of type '$MARK'"
- busy
- $_START_VSERVERS -m "$MARK" -j "$NUMPARALLEL" --all --stop
- _tellResult $?
- RETVAL=$?
- rm -f /var/lock/subsys/vservers-$MARK
- else
- msg_not_running "vservers of type '$MARK'"
- fi
- ;;
- restart)
- $0 stop
- $0 start
- exit $?
- ;;
- status)
- if [ -f /var/lock/subsys/vservers-$MARK ] ; then
- echo "vservers of type '$MARK' were started"
- else
- echo "vservers of type '$MARK' are not started"
- fi
- ;;
- *)
- echo "Usage: $0 {start|stop|restart|status}"
- exit 1
- ;;
-esac
-
-exit $RETVAL
-
-# This must be last line !
-# vi:syntax=sh:tw=78:ts=8:sw=4
+++ /dev/null
-## Number of vservers which shall be started in parallel; since most
-## initmethods are spending much time time in sleeps, it is safe to
-## use a high number here
-#NUMPARALLEL=99
-
-## The vserver-flavor; the 'default' vservers will be started very late
-## which may be inappropriately for early services like nameservers or
-## VPN tunnels. By copying this initscript to a new name and adapting
-## the startup-position (for RH/Fedora the numbers in line 2), other
-## vservers can be selected. Identification of vservers happens by
-## putting the flavor into /etc/vservers/<vserver-id>/apps/init/mark.
-MARK=default