View previous topic :: View next topic |
Author |
Message |
st1650 n00b

Joined: 13 Sep 2007 Posts: 3
|
Posted: Mon Mar 03, 2008 3:58 am Post subject: Cannot start rtorrent as daemon |
|
|
I've configured wtorrent to with with rtorrent using the scgi gateway. Everything works perfectly. But since I'm running an headless server, I'd like to have my rtorrent auto-start on boot as a daemon (Logical!)
So I did a simple init script :
Code: |
#!/sbin/runscript
depend() {
# the daemon needs the internet to function
need net
}
start() {
ebegin "Starting Example daemon"
start-stop-daemon --start --exec /usr/bin/rtorrent \
--pidfile /var/run/rtorrent.pid --make-pidfile --background
eend $?
}
stop() {
ebegin "Stopping Example daemon"
start-stop-daemon --stop --exec /usr/bin/rtorrent \
--pidfile /var/run/rtorrent.pid
eend $?
}
|
So when I run /etc/init.d/rtorrent start I get
* Starting Example daemon ... [ !!]
But when when I edit my rc-script and remove the --background the application launch fine.
So how would I go to run my rtorrent application in the background ? |
|
Back to top |
|
 |
mmoufid n00b

Joined: 21 Aug 2007 Posts: 22 Location: Ottawa ON
|
Posted: Mon Mar 03, 2008 7:31 am Post subject: |
|
|
Have you tried using screen?
Code: | screen -S rtorrent rtorrent |
|
|
Back to top |
|
 |
st1650 n00b

Joined: 13 Sep 2007 Posts: 3
|
Posted: Mon Mar 03, 2008 2:59 pm Post subject: |
|
|
mmoufid wrote: | Have you tried using screen?
Code: | screen -S rtorrent rtorrent |
|
It does launch the application but not as a daemon ...
How would I edit my init.d script to do it with screen ? |
|
Back to top |
|
 |
|