How to make a program/process a service under SysV-style init?
From what I found, noip2
includes the script /etc/init.d/noip2
, (also here, for those not running Debian right now) which should already be all you need. I'm not sure how services
interacts with the scripts in /etc/init.d
, but in general you could run
/etc/init.d/noip2 start
to start the noip2
service and
/etc/init.d/noip2 stop
to stop it. Have a look at the script, it shows how to wrap any such process into a system service (with a pidfile, for example) using start-stop-daemon
.
Related videos on Youtube
Patryk
Software Engineer C++/Go/shell/python coder Linux enthusiast Github profiles: https://github.com/pmalek https://github.com/pmalekn
Updated on September 18, 2022Comments
-
Patryk over 1 year
I wonder how can I make a regular application like for instance
noip2
updater a system process. I use Debian 6.0.2. For now I have it like this :- the binary is in the
/usr/local/bin/
asnoip2
file - the 'script' that launches is added to
/etc/rc.local
How can I make it a system service to be able to run/stop it with e.g.
service
command ?-
Admin about 12 yearsYou should probably tell us (Unix and Linux users) what makes something a "service", and what the "service" command does. I have only a vague idea how that relates to the Unix/Linux idea of a "daemon process".
- the binary is in the
-
Patryk about 12 years
-
sr_ about 12 yearsIndeed, it has been removed and there is no maintainer. (See also this bug report.) Probably time to (a) take over maintaining the package or (b) look for an alternative.