Managing Compiled Applications with Systemd
Hi guys,
in RHEL6, when you compile an application , you can put the start up script in /etc/init.d and symlink it to desired runlevel.
How is this done in RHEL7 ? How can I have a custom startup script managed by systemd?
Thanks
Responses
There are multiple ways to accomplish this. If you already have an init script for your application, systemd will allow you to use it -- it is backwards compatible with SysV init scripts, which makes it possible for you to just add your script to the desired rcX.d/ directory in /etc, and systemd will treat it as its own service unit.
Or you can write your own service file for systemd.
See the following resources for more information about systemd:
- RHEL7 System Administrator's Guide: Managing Services with systemd
- systemd manual page: systemd.service
Hi Arrey, does this solution help at all?
How to convert init scripts to systemd units files
We also have a more streamlined version that does not discuss init files:
How to make custom script that runs automatically during boot up in RHEL7?
br
Mark
[edit]Added second link
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
