Update of /cvsroot/devil-linux/build/scripts/scripts
In directory sc8-pr-cvs12.sourceforge.net:/tmp/cvs-serv30991/scripts/scripts
Added Files:
memcached
Log Message:
- added memcached 1.2.5
- added php pecl modules
Fileinfo-1.0.4
LZF-1.4
memcache-3.0.1
rar-1.0.0
zip-1.8.10
--- NEW FILE: memcached ---
#!/bin/bash
#
# $Source: /cvsroot/devil-linux/build/scripts/scripts/memcached,v $
# $Revision: 1.1 $
# $Date: 2008/06/05 14:38:52 $
#
# http://www.devil-linux.org
#
### BEGIN INIT INFO
# Provides: memcached
# Required-Start: $network $syslog $named
# Required-Stop: $network $syslog $named
# Default-Start: 2 3 5
# Default-Stop: 6 0
# Description: starts memcached
### END INIT INFO
# settings
source /etc/sysconfig/config
# parameters
NAME="memcached"
CONFIGNAME=MEMCACHED
DAEMON=/usr/sbin/memcached
PARAMETER="-d -u memcache -m $MEMCACHED_MAXMEM $MEMCACHE_PARAMS"
# source function library
source /etc/init.d/functions
eval START=\$START_$CONFIGNAME
# Determine the base and follow a runlevel link name.
base=${0##*/}
link=${base#*[SK][0-9][0-9]}
# Force execution if not called by a runlevel directory.
test $link = $base && START=yes
test "$START" = "yes" || exit 0
if [ ! -e $DAEMON ]; then
echo "$DAEMON not found. Did you install the package?"
exit 1
fi
case "$1" in
start)
echo -n "Starting $NAME"
loadproc $DAEMON $PARAMETER
;;
stop)
echo -n "Shutting down $NAME: "
killproc $DAEMON
;;
restart)
$0 stop
sleep 1
$0 start
;;
*)
echo "Usage: $0 {start|stop|restart|status}"
exit 1
esac
|