Re: Help setting up a daemon
On Sat, 31 May 1997, Randy Edwards wrote:
> I've been using fetchpop to grab my mail from my ISP. I recently got
> diald up and working and now I want to run fetchpop as a daemon process.
> I've set up a script (using apmd as a guide) in /etc/init.d called
> fetchpop and it contains the following:
>
> #! /bin/sh
> #
> # Start or stop fetchpop as a daemon.
> #
>
> test -s /usr/bin/fetchpop || exit 0
>
> case "$1" in
> start)
> echo "Starting fetchpop as a mail daemon"
> start-stop-daemon --start --quiet --exec /bin/su -- redwards -l -c "/usr/bin/fetchpop -d -r -l ~/fetchpop.log"
> ;;
> stop)
> echo "Stopping the fetchpop daemon process"
> start-stop-daemon --stop --quiet --oknodo --exec /usr/bin/fetchpop -- -q
> rm /home/redwards/.lockfetch-golgotha
> ;;
> *)
> echo "Usage: /etc/init.d/fetchpop {start|stop}"
> exit 1
> esac
>
> exit 0
>
> Then I went into each of the rc0.d through rc6.d subdirectories and
> created a symbolic link called K40fetchpop. This link simply points to
^^^^^^^^^^^S40fetchpop
S for start, K for kill, your are telling it to shutdown on startup!
> ../init.d/fetchpop.
>
> If boot the system and log in as root, go into /etc/init.d and type
> "fetchpop start" the program works perfectly. Likewise, a similar
> "fetchpop stop" works fine too. But for some reason, the program isn't
> getting started automatically at bootup. Can anyone see an error and/or
> tell me why/what I'm doing wrong? If so, I'd greatly appreciate it along
> with any suggestions you might have.
>
---------------- http://www.sound.net/~wpmills/ -----------------
: W. Paul Mills : Bill, I was there several years ago. :
: Topeka, Kansas, U.S.A. : Why would I want to go back tomorrow? :
: wpmills@midusa.net : Where were you! :
: wpmills@sound.net : ---------------------------------------- :
: paulmills@bix.com : Linux: Tomorrow's operating system, :
: paulmills@aol.com : here, today. :
: PAULMILLS@delphi.com : ---------------------------------------- :
: compuserve 70023,1750 : #define MY_TRUE_LOVE computer :
-------------- http://homepage.midusa.net/~wpmills/ -------------
--
TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-user-request@lists.debian.org .
Trouble? e-mail to templin@bucknell.edu .
Reply to: