Sample Header Ad - 728x90

What is the difference between start-stop-daemon and running with &?

19 votes
1 answer
14508 views
I am setting up a service in /etc/init.d. I am looking at various scripts in there, some are implemented with start-stop-daemon ... and some with /path/to/script &. All of them save the pid in a file and do some checks. What is the best practice, what are the differences, what is important to know here ... ? (in general) In my particular case I have a simple lightweight localhost http server in java that an application will call once every hour or so and it just gives a stupid random number (no more details here, I just mean it doesn't use the file system or threads or anything complicated in case this matter in my question) Thanks
Asked by Thomas (953 rep)
Oct 28, 2013, 03:21 PM
Last activity: Jun 5, 2024, 05:42 PM