[Home]

Summary:ASTERISK-25988: Asterisk is lacking a systemd unit file
Reporter:Sean Brady (SeanBrady)Labels:
Date Opened:2016-05-04 01:26:35Date Closed:2020-01-14 11:13:48.000-0600
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/Configuration
Versions:13.9.0 Frequency of
Occurrence
Related
Issues:
duplicatesASTERISK-21991 [patch] - install a systemd service unit
Environment:Any system with systemd as the init daemon, such as RHEL, Centos, Debian, Ubuntu, etc. Attachments:
Description:Asterisk has thus far been using the init.d compatibility scripts that have been adopted with multiple distros. This may cause issues in the future with systemd, and may eventually be deprecated.
Comments:By: Asterisk Team (asteriskteam) 2016-05-04 01:26:36.164-0500

Thanks for creating a report! The issue has entered the triage process. That means the issue will wait in this status until a Bug Marshal has an opportunity to review the issue. Once the issue has been reviewed you will receive comments regarding the next steps towards resolution.

A good first step is for you to review the [Asterisk Issue Guidelines|https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines] if you haven't already. The guidelines detail what is expected from an Asterisk issue report.

Then, if you are submitting a patch, please review the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process].

By: Sean Brady (SeanBrady) 2016-05-04 01:29:29.123-0500

I couldn't submit a file when creating the issue, but I can now. Attached is the systemd unit file that I have been using in production with success. Some modifications may be needed during installation, such as file paths. Some of the the checks for empty directories can also be removed. I feel like this is a good start for most users and platforms.

Tested and working on Debian 8.x and Centos 7.x.

By: Rusty Newton (rnewton) 2016-05-04 14:21:43.127-0500

Sean I don't see your attached file. I do see that you have completed a submission agreement and it was processed, so you should be able to submit a file as contribution.

Please see the [Patch Contribution Process|https://wiki.asterisk.org/wiki/display/AST/Patch+Contribution+Process] for how to work towards getting this into Asterisk.

By: Michael L. Young (elguero) 2016-05-04 15:02:59.802-0500

Just to add some information.  When I did research on this over a year ago, when setting up my first CentOS 7 box, the consensus that I found on the mailing lists as well as on the reviewboard link that is in ASTERISK-21991, was that we should be using the scripts found in upstream rather than trying to maintain it within Asterisk itself.

It doesn't matter to me either way but it would make sense that if there is a systemd file maintained by upstream, it would be best to stick to using that.

I did a quick search this morning and it would seem that these systemd scripts can be found for both RHEL/Fedora and Debian based distributions from upstream.  Perhaps a text file should be added to point people to these sources?

For instance, here is from Fedora: http://pkgs.fedoraproject.org/cgit/rpms/asterisk.git/tree/asterisk.service

By: Asterisk Team (asteriskteam) 2016-05-19 12:00:01.868-0500

Suspended due to lack of activity. This issue will be automatically re-opened if the reporter posts a comment. If you are not the reporter and would like this re-opened please create a new issue instead. If the new issue is related to this one a link will be created during the triage process. Further information on issue tracker usage can be found in the Asterisk Issue Guidlines [1].

[1] https://wiki.asterisk.org/wiki/display/AST/Asterisk+Issue+Guidelines