From: "Алексей Шенцев" <ashen@nsrz.ru>
To: ALT Linux Sisyphus discussion list <sisyphus@lists.altlinux.org>
Subject: Re: [sisyphus] dspam & chkconfig
Date: Mon, 27 Aug 2007 14:59:47 +0400
Message-ID: <200708271459.47868.ashen@nsrz.ru> (raw)
In-Reply-To: <20070827095311.GD2144@cryo.net.ru>
В сообщении от Monday 27 August 2007 13:53:11 Pavlov Konstantin написал(а):
> Если Вы про сервис dspam, то в init-файле:
Да.
> # chkconfig: 345 90 10
> запустит на 3, 4 и 5.
Хм ... не въехал куда именно прописывать ...
вот такой старт/стоп скрипт:
-(ashen@oasu3)-(~/work/dspam)-> cat dspam.init
#!/bin/sh
#
# chkconfig: 2345 80 30
# description: dspam daemon
# Do not load RH compatibility interface.
WITHOUT_RC_COMPAT=1
# Source function library.
. /etc/init.d/functions
LOCKFILE=/var/lock/subsys/dspam
PIDFILE=/var/run/dspam.pid
RETVAL=0
start()
{
action "Starting dspam service: "
start-stop-daemon --quiet --start -b --pidfile
$PIDFILE --exec /usr/bin/dspam -- --daemon
RETVAL=$?
return $RETVAL
}
stop()
{
action "Stopping dspam service: "
start-stop-daemon --stop --quiet --pidfile $PIDFILE dspam
RETVAL=$?
return $RETVAL
}
restart()
{
stop
sleep 1
start
}
# See how we were called.
case "$1" in
start)
start
;;
stop)
stop
;;
restart)
restart
;;
condstop)
if [ -e "$LOCKFILE" ]; then
stop
fi
;;
condrestart)
if [ -e "$LOCKFILE" ]; then
restart
fi
;;
status)
#status dspam
status --pidfile "$PIDFILE" --expect-user root -- dspam
RETVAL=$?
;;
*)
echo "Usage: ${0##*/} {start|stop|reload|restart|condstop|
condrestart|status}"
RETVAL=1
esac
exit $RETVAL
-(ashen@oasu3)-(~/work/dspam)->
И где, что прописывать?
--
С уважением Шенцев Алексей Владимирович.
E-mail: ashen@nsrz.ru
XMPP: ashen@altlinux.org, AlexShen@jabber.ru
ICQ: 271053845
next prev parent reply other threads:[~2007-08-27 10:59 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-27 9:47 Алексей Шенцев
2007-08-27 9:53 ` Pavlov Konstantin
2007-08-27 10:59 ` Алексей Шенцев [this message]
2007-08-27 11:45 ` Pavlov Konstantin
2007-08-27 19:39 ` Eugene Prokopiev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200708271459.47868.ashen@nsrz.ru \
--to=ashen@nsrz.ru \
--cc=sisyphus@lists.altlinux.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
ALT Linux Sisyphus discussions
This inbox may be cloned and mirrored by anyone:
git clone --mirror http://lore.altlinux.org/sisyphus/0 sisyphus/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 sisyphus sisyphus/ http://lore.altlinux.org/sisyphus \
sisyphus@altlinux.ru sisyphus@altlinux.org sisyphus@lists.altlinux.org sisyphus@lists.altlinux.ru sisyphus@lists.altlinux.com sisyphus@linuxteam.iplabs.ru sisyphus@list.linux-os.ru
public-inbox-index sisyphus
Example config snippet for mirrors.
Newsgroup available over NNTP:
nntp://lore.altlinux.org/org.altlinux.lists.sisyphus
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git