LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
LinkBack Search this Thread
Old 11-18-2008, 05:09 AM   #1
zoran119
Member
 
Registered: Dec 2007
Posts: 213

Rep: Reputation: 18
new daemon - start and stop questions


Hi, I have installed mpd (music player daemon) and wanted to check if what I'm planning to do is ok.

Now, the mpd package has put /etc/rc.d/rc.mpd in for me, but just making it executable was not enough to make it start.

Having a look through the scripts, this is my solution:

Add this to rc.M
Code:
if [ -x /etc/rc.d/rc.mpd ]; then
  /etc/rc.d/rc.mpd start
fi
Add this to rc.0
Code:
if [ -x /etc/rc.d/rc.mpd ]; then
  /etc/rc.d/rc.mpd stop
fi
Is this the best way of doing what I want?
 
Old 11-18-2008, 05:26 AM   #2
vladmihaisima
Member
 
Registered: Oct 2002
Location: Delft, Netherlands
Distribution: Gentoo
Posts: 196

Rep: Reputation: 33
This depends on the distrubution. On Fedora you can use "chkconfig". On Gentoo you can use "rc-update". Please specify distribution if you want more info...
 
Old 11-18-2008, 05:27 AM   #3
rg3
Member
 
Registered: Jul 2007
Distribution: Slackware Linux
Posts: 498

Rep: Reputation: Disabled
I'd put the starting block inside rc.local, and either ommit the stop block if it's fine, or put it inside rc.local_shutdown.
 
Old 11-18-2008, 05:39 AM   #4
zoran119
Member
 
Registered: Dec 2007
Posts: 213

Original Poster
Rep: Reputation: 18
Quote:
Originally Posted by rg3 View Post
I'd put the starting block inside rc.local, and either ommit the stop block if it's fine, or put it inside rc.local_shutdown.
That is much better than hacking at the rc.M and rc.0.

Thank you!
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Using debian start-stop-daemon on Centos powadha Linux - Software 1 11-02-2008 05:59 AM
Unexpected error messages with start-stop-daemon markseger Debian 3 10-29-2008 08:14 PM
start-stop-daemon for linux eliufoo Linux - Software 1 02-07-2008 02:12 AM
fake start-stop-daemon, messed up install tripmix Linux - Software 2 02-23-2007 11:11 PM
Logging with Start stop daemon bigsness Linux - General 0 01-19-2005 03:25 PM


All times are GMT -5. The time now is 05:11 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration